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
What steps will reproduce the problem?
Checkout credis and build it
What is the expected output? What do you see instead?
Expected: built succesfully
Actual output:
cc -shared -Wl,-soname,libcredis.so -o libcredis.so credis.o
ld: unknown option: -soname
collect2: ld returned 1 exit status
gmake: *** [libcredis.so] Error 1
What version of the product are you using? On what operating system?
svn r8, OS X 10.6.2, gcc version 4.2.1
Please provide any additional information below.
"""
=== modified file 'Makefile'
--- Makefile 2009-12-03 21:30:48 +0000
+++ Makefile 2010-01-01 06:33:35 +0000
@@ -2,6 +2,13 @@
LDFLAGS =
CPPFLAGS =
+OS = $(shell uname -s)
+ifeq ($(OS),Darwin)
+ SHAREDLIB_LINK_OPTIONS=-dynamiclib -Wl,-install_name -Wl,
+else
+ SHAREDLIB_LINK_OPTIONS=-shared -Wl,-soname,
+endif
+
# targets to build with 'make all'
TARGETS = credis-test libcredis.a libcredis.so
@@ -14,7 +21,8 @@
$(AR) -cvq $@ $^
libcredis.so: credis.o
- $(CC) -shared -Wl,-soname,$@ -o $@ $^
+ $(CC) $(SHAREDLIB_LINK_OPTIONS)$@ -o $@ $^
+
credis.o: credis.c credis.h
$(CC) -c -fPIC $(CFLAGS) $(CPPFLAGS) -o $@ credis.c
"""
See also.
http://lists.ozlabs.org/pipermail/devicetree-discuss/2009-May/000818.html
http://www.finkproject.org/doc/porting/porting.en.html
Original issue reported on code.google.com by akit...@gmail.com on 1 Jan 2010 at 6:34
The text was updated successfully, but these errors were encountered:
Original issue reported on code.google.com by
akit...@gmail.com
on 1 Jan 2010 at 6:34The text was updated successfully, but these errors were encountered: