summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2023-06-27 00:37:04 +0800
committerruki <[email protected]>2023-06-27 00:37:04 +0800
commitf2b86d2313b30a29d8a1de6377e5c27da5f4a541 (patch)
treea66e501fafb636d63247d08606c37efad5f3c732
parent649faaf87d7cb1eab632d89be89fc12ebfe4e3a2 (diff)
update configure
-rwxr-xr-xconfigure16
m---------core/src/tbox/tbox0
2 files changed, 12 insertions, 4 deletions
diff --git a/configure b/configure
index 35d19f955..fc11bd2bf 100755
--- a/configure
+++ b/configure
@@ -1587,8 +1587,12 @@ _get_target_toolchain_flags_for_gcc() {
flags="${flags} -m32"
fi
_get_target_item "${name}" "kind"; local targetkind="${_ret}"
- if test_eq "${targetkind}" "shared" && test_eq "${toolkind}" "sh"; then
- flags="${flags} -shared -fPIC"
+ if test_eq "${targetkind}" "shared"; then
+ if test_eq "${toolkind}" "sh"; then
+ flags="${flags} -shared -fPIC"
+ elif test_eq "${toolkind}" "cc" || test_eq "${toolkind}" "cxx"; then
+ flags="${flags} -fPIC"
+ fi
fi
_ret="${flags}"
}
@@ -1602,8 +1606,12 @@ _get_target_toolchain_flags_for_clang() {
flags="${flags} -m32"
fi
_get_target_item "${name}" "kind"; local targetkind="${_ret}"
- if test_eq "${targetkind}" "shared" && test_eq "${toolkind}" "sh"; then
- flags="${flags} -shared -fPIC"
+ if test_eq "${targetkind}" "shared"; then
+ if test_eq "${toolkind}" "sh"; then
+ flags="${flags} -shared -fPIC"
+ elif test_eq "${toolkind}" "cc" || test_eq "${toolkind}" "cxx"; then
+ flags="${flags} -fPIC"
+ fi
fi
if is_plat "macosx"; then
_os_iorunv "xcrun" "-sdk" "macosx" "--show-sdk-path"; local sdkdir="${_ret}"
diff --git a/core/src/tbox/tbox b/core/src/tbox/tbox
-Subproject b276eb4a88a0fec17b3edf2c987a372136c8b30
+Subproject 3d5dbfafef53a670214c69ffc069a5127cee454