mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-02-27 17:21:05 +00:00
Merge commit '857e26b655a769e5a56bada1a0d9adb44cc176b7'
* commit '857e26b655a769e5a56bada1a0d9adb44cc176b7':
build: Add an option for passing linker flags to the shared library build
See e34a3468f2
.
--extra-ldlibflags is left in place for compatibility reasons.
Merged-by: James Almer <jamrial@gmail.com>
This commit is contained in:
commit
88d6f79ac0
18
configure
vendored
18
configure
vendored
@ -365,7 +365,7 @@ Toolchain options:
|
||||
--extra-objcflags=FLAGS add FLAGS to OBJCFLAGS [$CFLAGS]
|
||||
--extra-ldflags=ELDFLAGS add ELDFLAGS to LDFLAGS [$LDFLAGS]
|
||||
--extra-ldexeflags=ELDFLAGS add ELDFLAGS to LDEXEFLAGS [$LDEXEFLAGS]
|
||||
--extra-ldlibflags=ELDFLAGS add ELDFLAGS to LDLIBFLAGS [$LDLIBFLAGS]
|
||||
--extra-ldsoflags=ELDFLAGS add ELDFLAGS to LDSOFLAGS [$LDSOFLAGS]
|
||||
--extra-libs=ELIBS add ELIBS [$ELIBS]
|
||||
--extra-version=STRING version string suffix []
|
||||
--optflags=OPTFLAGS override optimization-related compiler flags
|
||||
@ -869,8 +869,8 @@ add_ldexeflags(){
|
||||
append LDEXEFLAGS $($ldflags_filter "$@")
|
||||
}
|
||||
|
||||
add_ldlibflags(){
|
||||
append LDLIBFLAGS $($ldflags_filter "$@")
|
||||
add_ldsoflags(){
|
||||
append LDSOFLAGS $($ldflags_filter "$@")
|
||||
}
|
||||
|
||||
add_stripflags(){
|
||||
@ -3604,8 +3604,13 @@ for opt do
|
||||
--extra-ldexeflags=*)
|
||||
add_ldexeflags $optval
|
||||
;;
|
||||
--extra-ldsoflags=*)
|
||||
add_ldsoflags $optval
|
||||
;;
|
||||
--extra-ldlibflags=*)
|
||||
add_ldlibflags $optval
|
||||
warn "The --extra-ldlibflags option is only provided for compatibility and will be\n"\
|
||||
"removed in the future. Use --extra-ldsoflags instead."
|
||||
add_ldsoflags $optval
|
||||
;;
|
||||
--extra-libs=*)
|
||||
add_extralibs $optval
|
||||
@ -6361,8 +6366,7 @@ EOF
|
||||
# add some linker flags
|
||||
check_ldflags -Wl,--warn-common
|
||||
check_ldflags -Wl,-rpath-link=libpostproc:libswresample:libswscale:libavfilter:libavdevice:libavformat:libavcodec:libavutil:libavresample
|
||||
enabled rpath && add_ldexeflags -Wl,-rpath,$libdir
|
||||
enabled rpath && add_ldlibflags -Wl,-rpath,$libdir
|
||||
enabled rpath && add_ldexeflags -Wl,-rpath,$libdir && add_ldsoflags -Wl,-rpath,$libdir
|
||||
test_ldflags -Wl,-Bsymbolic && append SHFLAGS -Wl,-Bsymbolic
|
||||
|
||||
# add some strip flags
|
||||
@ -6954,7 +6958,7 @@ DEPWINDRES=$dep_cc
|
||||
DOXYGEN=$doxygen
|
||||
LDFLAGS=$LDFLAGS
|
||||
LDEXEFLAGS=$LDEXEFLAGS
|
||||
LDLIBFLAGS=$LDLIBFLAGS
|
||||
LDSOFLAGS=$LDSOFLAGS
|
||||
SHFLAGS=$(echo $($ldflags_filter $SHFLAGS))
|
||||
ASMSTRIPFLAGS=$ASMSTRIPFLAGS
|
||||
X86ASMFLAGS=$X86ASMFLAGS
|
||||
|
@ -48,7 +48,7 @@ $(SUBDIR)$(SLIBNAME): $(SUBDIR)$(SLIBNAME_WITH_MAJOR)
|
||||
|
||||
$(SUBDIR)$(SLIBNAME_WITH_MAJOR): $(OBJS) $(SLIBOBJS) $(SUBDIR)lib$(NAME).ver
|
||||
$(SLIB_CREATE_DEF_CMD)
|
||||
$$(LD) $(SHFLAGS) $(LDFLAGS) $(LDLIBFLAGS) $$(LD_O) $$(filter %.o,$$^) $(FFEXTRALIBS)
|
||||
$$(LD) $(SHFLAGS) $(LDFLAGS) $(LDSOFLAGS) $$(LD_O) $$(filter %.o,$$^) $(FFEXTRALIBS)
|
||||
$(SLIB_EXTRA_CMD)
|
||||
|
||||
ifdef SUBDIR
|
||||
|
Loading…
Reference in New Issue
Block a user