[vlc-commits] contrib: vpx: remove strip step and fix debug symbols
Alexandre Janniaux
git at videolan.org
Tue May 19 16:21:04 CEST 2020
vlc | branch: master | Alexandre Janniaux <ajanni at videolabs.io> | Thu Apr 30 11:39:14 2020 +0200| [52e22b96239cc3784aa13495be92f5f3ce591bf1] | committer: Alexandre Janniaux
contrib: vpx: remove strip step and fix debug symbols
Without CONFIG_DEBUG set, libvpx is calling `$(STRIP) --strip-debug`
on the final library and removes the debug symbols from it. With the
variable set, it becomes a simple copy operation.
In addition, debug symbols should be enabled for all builds since we
strip in the end, so as to have the debug symbols in a separate file
when doing releases. In case we build with optimization, remove the
assertions.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=52e22b96239cc3784aa13495be92f5f3ce591bf1
---
contrib/src/vpx/rules.mak | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/contrib/src/vpx/rules.mak b/contrib/src/vpx/rules.mak
index 6cd16739ea..83b6503ff5 100644
--- a/contrib/src/vpx/rules.mak
+++ b/contrib/src/vpx/rules.mak
@@ -146,10 +146,15 @@ ifneq ($(filter i386 x86_64,$(ARCH)),)
VPX_CONF += --disable-mmx
endif
-ifndef WITH_OPTIMIZATION
-VPX_CONF += --enable-debug --disable-optimizations
+ifdef WITH_OPTIMIZATION
+VPX_CFLAGS += -DNDEBUG
+else
+VPX_CONF += --disable-optimizations
endif
+# Always enable debug symbols, we strip in the final executables if needed
+VPX_CONF += --enable-debug
+
ifdef HAVE_ANDROID
# Starting NDK19, standalone toolchains are deprecated and gcc is not shipped.
# The presence of gcc can be used to detect if we are using an old standalone
@@ -164,7 +169,7 @@ endif
rm -rf $(PREFIX)/include/vpx
cd $< && LDFLAGS="$(VPX_LDFLAGS)" CROSS=$(VPX_CROSS) $(VPX_HOSTVARS) ./configure --target=$(VPX_TARGET) \
$(VPX_CONF) --prefix=$(PREFIX)
- cd $< && $(MAKE)
+ cd $< && CONFIG_DEBUG=1 $(MAKE)
$(call pkg_static,"vpx.pc")
- cd $< && $(MAKE) install
+ cd $< && CONFIG_DEBUG=1 $(MAKE) install
touch $@
More information about the vlc-commits
mailing list