[MPlayer-dev-eng] Compiling MPlayer under Wine

Ingo Brückl ib at wupperonline.de
Thu Oct 6 23:37:28 CEST 2011


I wrote on Thu, 06 Oct 2011 17:59:48 +0200:

> #4: I initially used target=mingw32, but this enables Windows stuff
>     (_getch=getch2-win.c and shmem=yes at line 1562) we don't want.

With a new target wine we can put the extra-cflags stuff into the config.

Ingo
-------------- next part --------------
--- configure	2011-10-01 17:32:38.000000000 +0200
+++ /home/ib/mplayer/configure	2011-10-06 23:35:16.000000000 +0200
@@ -240,7 +240,8 @@
 os2()       { issystem "OS/2"; }
 qnx()       { issystem "QNX"; }
 sunos()     { issystem "SunOS"; }
-win32()     { cygwin || mingw32; }
+wine()      { issystem "Wine"; }
+win32()     { cygwin || mingw32 || wine; }
 
 # arch test boolean functions
 # x86/x86pc is used by QNX
@@ -1514,6 +1515,7 @@
     morphos) system_name=MorphOS ;;
     amigaos) system_name=AmigaOS ;;
     mingw32*) system_name=MINGW32 ;;
+    wine) system_name=Wine ;;
   esac
   # We need to convert underscores so that values like k6-2 and pentium-mmx can be passed
   host_arch=$(echo $_target | cut -d '-' -f 1)
@@ -1583,6 +1585,10 @@
   def_priority="#define CONFIG_PRIORITY 1"
 fi
 
+if wine ; then
+  extra_cflags="-fno-pic -UWIN32 -U_WIN32 -U__WIN32 -U__WIN32__ -DWINE_NOWINSOCK -DHAVE_LINUX_DVD_STRUCT -Dstricmp=strcasecmp $extra_cflags"
+fi
+
 for tmpdir in "$TMPDIR" "$TEMPDIR" "/tmp" ; do
   test "$tmpdir" && break
 done


More information about the MPlayer-dev-eng mailing list