meta-openembedded/meta-oe/recipes-multimedia/webm/libvpx/libvpx-configure-support-blank-prefix.patch
Koen Kooi 7ad1aec3ed libvpx 0.9.5: import from OE rev e02237d7e46e60fbd9eb4a05a308e6adcf916ebb
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
2011-08-17 09:21:11 +02:00

44 lines
1.0 KiB
Diff

Upstream: not yet
Fix configure to accept "--prefix=" (a blank prefix).
--- libvpx-0.9.1/build/make/configure.sh.orig 2010-06-17 09:08:56.000000000 -0400
+++ libvpx-0.9.1/build/make/configure.sh 2010-09-23 14:27:48.000000000 -0400
@@ -444,6 +444,8 @@
;;
--prefix=*)
prefix="${optval}"
+ # Distinguish between "prefix not set" and "prefix set to ''"
+ prefixset=1
;;
--libdir=*)
libdir="${optval}"
@@ -471,13 +473,23 @@
post_process_common_cmdline() {
- prefix="${prefix:-/usr/local}"
+ if [ "$prefixset" != "1" ]
+ then
+ prefix=/usr/local
+ fi
+
+ # Strip trailing slash
prefix="${prefix%/}"
+
libdir="${libdir:-${prefix}/lib}"
libdir="${libdir%/}"
- if [ "${libdir#${prefix}}" = "${libdir}" ]; then
- die "Libdir ${libdir} must be a subdirectory of ${prefix}"
- fi
+
+ case "$libdir" in
+ "${prefix}/"*) ;;
+ *)
+ die "Libdir ${libdir} must be a subdirectory of ${prefix}"
+ ;;
+ esac
}