]> git.ipfire.org Git - thirdparty/libbsd.git/commitdiff
build: Use CCLD instead of hardcoded gcc for linking
authorGuillem Jover <guillem@hadrons.org>
Sat, 30 Jan 2010 21:40:01 +0000 (22:40 +0100)
committerGuillem Jover <guillem@hadrons.org>
Sat, 30 Jan 2010 21:40:01 +0000 (22:40 +0100)
Makefile

index 05f344d9566ea337880bbc74a4a2a47bece3d501..5c5a6904f315f6947458dd9f91c6f68696b4756e 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -101,6 +101,7 @@ LIB_STATIC_OBJS := $(LIB_SRCS:%.c=%.o)
 LIB_SHARED_OBJS := $(LIB_SRCS:%.c=%.lo)
 
 CC = gcc
+CCLD = $(CC)
 
 # Set default value for compilation
 CFLAGS ?= -g -Wall -Wextra -Wno-unused-variable
@@ -151,7 +152,8 @@ $(LIB_SONAME): $(LIB_SHARED)
        ln -fs $^ $@
 
 $(LIB_SHARED): $(LIB_SHARED_OBJS)
-       gcc -shared \
+       $(CCLD) \
+         -shared \
          -Wl,-soname -Wl,$(LIB_SONAME) \
          -Wl,--version-script=Versions \
          -o $@ $^