projects
/
clsql.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove 32-bit builds on 64-bit Linux
[clsql.git]
/
uffi
/
Makefile
diff --git
a/uffi/Makefile
b/uffi/Makefile
index b24f37603a49f73be9c53a631f37938417192a74..8ae1fd95c9d7b85397d1b1e5c9484f8aadec6e08 100644
(file)
--- a/
uffi/Makefile
+++ b/
uffi/Makefile
@@
-23,6
+23,12
@@
shared_lib=$(base).so
shared64_lib=$(base)64.so
dylib=$(base).dylib
shared64_lib=$(base)64.so
dylib=$(base).dylib
+ifneq ($(OS_DPKG_BUILDFLAGS),0)
+ CFLAGS:=$(CFLAGS) $(shell dpkg-buildflags --get CFLAGS)
+ LDFLAGS:=$(LDFLAGS) $(shell DEB_BUILD_MAINT_OPTIONS=hardening=+all,-pie dpkg-buildflags --get LDFLAGS | sed "s/-Wl\|,/ /ig")
+endif
+
+
.PHONY: all
all: $(shared_lib)
.PHONY: all
all: $(shared_lib)
@@
-48,12
+54,12
@@
else
ld -shared -soname=$(base) $(LDFLAGS) $(object) -o $(shared_lib)
else
ifneq ($(OS_LINUX64),0)
ld -shared -soname=$(base) $(LDFLAGS) $(object) -o $(shared_lib)
else
ifneq ($(OS_LINUX64),0)
- gcc -fPIC -DPIC -c $(source) -o $(object)
-
ld -shared
-soname=$(base) -lc $(object) -o $(shared64_lib)
+ gcc
$(CFLAGS)
-fPIC -DPIC -c $(source) -o $(object)
+
gcc $(LDFLAGS) -fPIC -shared -Wl,
-soname=$(base) -lc $(object) -o $(shared64_lib)
rm -f $(object)
rm -f $(object)
- @echo "Ensure that you have multiarch i386 build tools if you want to build 32-bit library"
-
-gcc -m32
-fPIC -DPIC -c $(source) -o $(object)
-
-ld -melf_i386 -shared
-soname=$(base) -lc $(object) -o $(shared_lib)
+
#
@echo "Ensure that you have multiarch i386 build tools if you want to build 32-bit library"
+
#-gcc -m32 $(CFLAGS)
-fPIC -DPIC -c $(source) -o $(object)
+
#-gcc -m32 $(LDFLAGS) -fPIC -shared -Wl,
-soname=$(base) -lc $(object) -o $(shared_lib)
else
gcc -fPIC -DPIC -c $(source) -o $(object)
ld -shared -soname=$(base) -lc $(object) -o $(shared_lib)
else
gcc -fPIC -DPIC -c $(source) -o $(object)
ld -shared -soname=$(base) -lc $(object) -o $(shared_lib)