summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2019-06-18 22:24:41 +0000
committermidipix <writeonce@midipix.org>2019-06-18 22:24:41 +0000
commit66dce28eb51debc1ca5bdde9c85ede3127a0969f (patch)
tree55c98bcaea52dc69315cf3671d8b8e96f185ee40 /src
parent0d693ebc97d098589fc4ae78ecba9a4b082bca1e (diff)
downloadslibtool-66dce28eb51debc1ca5bdde9c85ede3127a0969f.tar.bz2
slibtool-66dce28eb51debc1ca5bdde9c85ede3127a0969f.tar.xz
slbt_exec_compile(): adding missing -fPIC bits for the --tag=F77.
Diffstat (limited to 'src')
-rw-r--r--src/logic/slbt_exec_compile.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/src/logic/slbt_exec_compile.c b/src/logic/slbt_exec_compile.c
index 8efa777..3ccea3c 100644
--- a/src/logic/slbt_exec_compile.c
+++ b/src/logic/slbt_exec_compile.c
@@ -165,11 +165,18 @@ int slbt_exec_compile(
ectx->argv = ectx->cargv;
/* -fpic */
- fpic = *ectx->fpic;
-
- if ((cctx->tag == SLBT_TAG_CC) || (cctx->tag == SLBT_TAG_CXX))
- if (cctx->settings.picswitch)
- fpic = cctx->settings.picswitch;
+ switch (cctx->tag) {
+ case SLBT_TAG_CC:
+ case SLBT_TAG_CXX:
+ case SLBT_TAG_F77:
+ fpic = cctx->settings.picswitch
+ ? cctx->settings.picswitch
+ : *ectx->fpic;
+ break;
+
+ default:
+ fpic = *ectx->fpic;
+ }
/* shared library object */
if (cctx->drvflags & SLBT_DRIVER_SHARED) {