[MPlayer-dev-eng] [PATCH] Detect extern_prefix correctly on OpenBSD

Edd Barrett vext01 at gmail.com
Tue Aug 3 01:09:15 CEST 2010


Hi,

I am going to try and get mplayer working out of the box on OpenBSD. Let's start
with this:

nm prints results differently on OpenBSD than on linux. We have been using this
following patch for a while in our ports tree. I hope I am correct to
patch the configure script directly. I see no GNU autotools inputs, so I
am assuming the script is written by hand.

Index: configure
===================================================================
--- configure	(revision 31906)
+++ configure	(working copy)
@@ -2508,7 +2508,11 @@
 int ff_extern;
 EOF
 cc_check -c || die "Symbol mangling check failed."
-sym=$($_nm -P -g $TMPEXE)
+if openbsd; then
+  sym=$($_nm -g $TMPEXE | grep ff_extern | cut -d ' ' -f 3)
+else
+  sym=$($_nm -P -g $TMPEXE)
+fi
 extern_prefix=${sym%%ff_extern*}
 def_extern_asm="#define EXTERN_ASM $extern_prefix"
 def_extern_prefix="#define EXTERN_PREFIX \"$extern_prefix\""

-- 
Best Regards
Edd Barrett

http://www.theunixzoo.co.uk


More information about the MPlayer-dev-eng mailing list