mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
configure.ac: leave LDFLAGS resolving on make time
Use LDFLAGS separately with every use of CLDFLAGS and leave this flag only for handling versioning. This will reflect any LDFLAGS setting use during make.
This commit is contained in:
parent
5d23054cb3
commit
f022da9e5f
@ -57,7 +57,7 @@ AS_CASE(["$host_os"],
|
|||||||
FSADM="no"
|
FSADM="no"
|
||||||
LVMIMPORTVDO="no"
|
LVMIMPORTVDO="no"
|
||||||
BLKDEACTIVATE="no"],
|
BLKDEACTIVATE="no"],
|
||||||
[CLDFLAGS="${CLDFLAGS-"$LDFLAGS"}"])
|
[])
|
||||||
|
|
||||||
################################################################################
|
################################################################################
|
||||||
dnl -- Checks for programs.
|
dnl -- Checks for programs.
|
||||||
@ -836,7 +836,7 @@ AS_IF([test "$GCC" = "yes" && test "$symvers" = "gnu"], [
|
|||||||
[Define to use GNU versioning in the shared library.])
|
[Define to use GNU versioning in the shared library.])
|
||||||
AS_CASE(["$host_os"],
|
AS_CASE(["$host_os"],
|
||||||
[linux*], [
|
[linux*], [
|
||||||
CLDFLAGS="${CLDFLAGS-"$LDFLAGS"} -Wl,--version-script,.export.sym"
|
CLDFLAGS="-Wl,--version-script,.export.sym"
|
||||||
LDDEPS="$LDDEPS .export.sym"])
|
LDDEPS="$LDDEPS .export.sym"])
|
||||||
])
|
])
|
||||||
|
|
||||||
|
@ -434,7 +434,7 @@ DEFS+=-D_FILE_OFFSET_BITS=64
|
|||||||
|
|
||||||
%.so: %.o
|
%.so: %.o
|
||||||
$(SHOW) " [CC] $(<F)"
|
$(SHOW) " [CC] $(<F)"
|
||||||
$(Q) $(CC) -c $(CFLAGS) $(CLDFLAGS) $< $(LIBS) -o $@
|
$(Q) $(CC) -c $(CFLAGS) $(LDFLAGS) $(CLDFLAGS) $< $(LIBS) -o $@
|
||||||
|
|
||||||
ifneq (,$(LIB_SHARED))
|
ifneq (,$(LIB_SHARED))
|
||||||
|
|
||||||
@ -443,11 +443,11 @@ $(LIB_SHARED).$(LIB_VERSION): $(OBJECTS) $(LDDEPS)
|
|||||||
$(SHOW) " [CC] $@"
|
$(SHOW) " [CC] $@"
|
||||||
ifeq ("@LIB_SUFFIX@","so")
|
ifeq ("@LIB_SUFFIX@","so")
|
||||||
$(Q) $(CC) -shared -Wl,-soname,$(notdir $@) \
|
$(Q) $(CC) -shared -Wl,-soname,$(notdir $@) \
|
||||||
$(CFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
$(CFLAGS) $(LDFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
||||||
endif
|
endif
|
||||||
ifeq ("@LIB_SUFFIX@","dylib")
|
ifeq ("@LIB_SUFFIX@","dylib")
|
||||||
$(Q) $(CC) -dynamiclib -dylib_current_version,$(LIB_VERSION) \
|
$(Q) $(CC) -dynamiclib -dylib_current_version,$(LIB_VERSION) \
|
||||||
$(CFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
$(CFLAGS) $(LDFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
||||||
endif
|
endif
|
||||||
|
|
||||||
$(LIB_SHARED): $(LIB_SHARED).$(LIB_VERSION)
|
$(LIB_SHARED): $(LIB_SHARED).$(LIB_VERSION)
|
||||||
|
@ -508,7 +508,7 @@ DEFS+=-D_FILE_OFFSET_BITS=64
|
|||||||
|
|
||||||
%.so: %.o
|
%.so: %.o
|
||||||
$(SHOW) " [CC] $(<F)"
|
$(SHOW) " [CC] $(<F)"
|
||||||
$(Q) $(CC) -c $(CFLAGS) $(CLDFLAGS) $< $(LIBS) -o $@
|
$(Q) $(CC) -c $(CFLAGS) $(LDFLAGS) $(CLDFLAGS) $< $(LIBS) -o $@
|
||||||
|
|
||||||
ifneq (,$(LIB_SHARED))
|
ifneq (,$(LIB_SHARED))
|
||||||
|
|
||||||
@ -517,11 +517,11 @@ $(LIB_SHARED).$(LIB_VERSION): $(OBJECTS) $(LDDEPS)
|
|||||||
$(SHOW) " [CC] $@"
|
$(SHOW) " [CC] $@"
|
||||||
ifeq ("@LIB_SUFFIX@","so")
|
ifeq ("@LIB_SUFFIX@","so")
|
||||||
$(Q) $(CC) -shared -Wl,-soname,$(notdir $@) \
|
$(Q) $(CC) -shared -Wl,-soname,$(notdir $@) \
|
||||||
$(CFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
$(CFLAGS) $(LDFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
||||||
endif
|
endif
|
||||||
ifeq ("@LIB_SUFFIX@","dylib")
|
ifeq ("@LIB_SUFFIX@","dylib")
|
||||||
$(Q) $(CC) -dynamiclib -dylib_current_version,$(LIB_VERSION) \
|
$(Q) $(CC) -dynamiclib -dylib_current_version,$(LIB_VERSION) \
|
||||||
$(CFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
$(CFLAGS) $(LDFLAGS) $(CLDFLAGS) $(OBJECTS) $(LIBS) -o $@
|
||||||
endif
|
endif
|
||||||
|
|
||||||
$(LIB_SHARED): $(LIB_SHARED).$(LIB_VERSION)
|
$(LIB_SHARED): $(LIB_SHARED).$(LIB_VERSION)
|
||||||
|
@ -155,7 +155,7 @@ liblvm2cmd-static.a: $(top_builddir)/lib/liblvm-internal.a $(OBJECTS) lvmcmdlib.
|
|||||||
liblvm2cmd.$(LIB_SUFFIX): liblvm2cmd.a $(LDDEPS)
|
liblvm2cmd.$(LIB_SUFFIX): liblvm2cmd.a $(LDDEPS)
|
||||||
$(SHOW) " [CC] $@"
|
$(SHOW) " [CC] $@"
|
||||||
$(Q) $(CC) -shared -Wl,-soname,$@.$(LIB_VERSION) \
|
$(Q) $(CC) -shared -Wl,-soname,$@.$(LIB_VERSION) \
|
||||||
$(CFLAGS) $(CLDFLAGS) -o $@ \
|
$(CFLAGS) $(LDFLAGS) $(CLDFLAGS) -o $@ \
|
||||||
@CLDWHOLEARCHIVE@ $< @CLDNOWHOLEARCHIVE@ \
|
@CLDWHOLEARCHIVE@ $< @CLDNOWHOLEARCHIVE@ \
|
||||||
$(INTERNAL_LIBS) $(LVMLIBS)
|
$(INTERNAL_LIBS) $(LVMLIBS)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user