Skip to content
You signed in with another tab or window. Reload to refresh your session.
You signed out in another tab or window. Reload to refresh your session.
You switched accounts on another tab or window. Reload to refresh your session.
Dismiss alert
File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -111,6 +111,7 @@ function push_arm() {
111
111
export OLD_PATH=$PATH
112
112
export OLD_CFLAGS=$CFLAGS
113
113
export OLD_CXXFLAGS=$CXXFLAGS
114
+ export OLD_LDFLAGS=$LDFLAGS
114
115
export OLD_CC=$CC
115
116
export OLD_CXX=$CXX
116
117
export OLD_AR=$AR
@@ -123,12 +124,15 @@ function push_arm() {
123
124
# export OFLAG="-Os"
124
125
# export OFLAG="-O2"
125
126
126
- export CFLAGS=" -mandroid $OFLAG -fomit-frame-pointer --sysroot $NDKPLATFORM "
127
+ export CFLAGS=" -mandroid $OFLAG -fomit-frame-pointer --sysroot $NDKPLATFORM -fPIC "
127
128
if [ $ARCH == " armeabi-v7a" ]; then
128
129
CFLAGS+=" -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -mthumb"
129
130
fi
130
131
export CXXFLAGS=" $CFLAGS "
131
132
133
+ # that could be done only for darwin platform, but it doesn't hurt.
134
+ export LDFLAGS=" -lm"
135
+
132
136
# this must be something depending of the API level of Android
133
137
PYPLATFORM=$( python -c ' import sys; print sys.platform' )
134
138
if [ " $PYPLATFORM " == " linux2" ]; then
@@ -182,6 +186,7 @@ function pop_arm() {
182
186
export PATH=$OLD_PATH
183
187
export CFLAGS=$OLD_CFLAGS
184
188
export CXXFLAGS=$OLD_CXXFLAGS
189
+ export LDFLAGS=$OLD_LDFLAGS
185
190
export CC=$OLD_CC
186
191
export CXX=$OLD_CXX
187
192
export AR=$OLD_AR
You can’t perform that action at this time.
0 commit comments