[PD-dev] building with msys2

patrice colet colet.patrice at free.Fr
Wed Jul 12 04:05:03 CEST 2017



Le 11/07/2017 à 17:37, IOhannes m zmoelnig a écrit :
> On 2017-07-11 17:26, patrice colet wrote:
>> I don't get why gcc is saying this:
> there's at least one pull request on github that tries to eliminate
> duplicate declarations (which is one of the errors you are getting).
> did you try it?

I've just tried with git sources, those errors have disappeared, 
meanwhile the attached patch helps to recognize my platform, I've forked 
mingw flags following this command return:

$ uname -a
MSYS_NT-10.0 DESKTOP-GUFTF62 2.6.0(0.304/5/3) 2016-09-07 20:45 x86_64 Msys

I'm pleased to see that build system works without src/makefile.mingw,
  --enable-asio works if I export the asiosdk headers directories,
  I don't know how to tweak the makefiles for having portaudio finding them.

pc

> fgmasdr
> IOhannes
>
>
>
> _______________________________________________
> Pd-dev mailing list
> Pd-dev at lists.iem.at
> https://lists.puredata.info/listinfo/pd-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-dev/attachments/20170712/37142b33/attachment-0001.html>
-------------- next part --------------
--- configure.ac.old	2017-07-12 01:43:06.173521800 +0200
+++ configure.ac	2017-07-12 01:40:14.835392300 +0200
@@ -115,6 +115,28 @@
     ac_cv_func_malloc_0_nonnull=yes
     ac_cv_func_realloc_0_nonnull=yes
     ;;
+
+*Msys*)
+    WINDOWS=yes
+    MINGW=yes
+    platform=MinGW
+    portaudio=yes
+    portmidi=yes
+
+    # ASIO doesn't build yet with the autotools setup. We need to figure out how
+    # to make the final linking phase use g++
+    asio=yes
+
+    # externals are dynamically linked to pd.dll in their individual automake files
+    EXTERNAL_CFLAGS="-mms-bitfields"
+    EXTERNAL_LDFLAGS="-s -Wl,--enable-auto-import -no-undefined -lpd"
+    EXTERNAL_EXTENSION=dll
+
+    # workaround for rpl_malloc/rpl_realloc bug in autoconf when cross-compiling
+    ac_cv_func_malloc_0_nonnull=yes
+    ac_cv_func_realloc_0_nonnull=yes
+    ;;
+	
 *cygwin*)
     WINDOWS=yes
     CYGWIN=yes
@@ -140,6 +162,7 @@
 AM_CONDITIONAL(WINDOWS, test x$WINDOWS = xyes)
 AM_CONDITIONAL(CYGWIN, test x$CYGWIN = xyes)
 AM_CONDITIONAL(MINGW, test x$MINGW = xyes)
+AM_CONDITIONAL(MSYS, test x$MSYS = xyes)
 
 
 #########################################
--- configure.ac.old	2017-07-12 01:43:06.173521800 +0200
+++ configure.ac	2017-07-12 01:57:22.571764500 +0200
@@ -115,6 +115,28 @@
     ac_cv_func_malloc_0_nonnull=yes
     ac_cv_func_realloc_0_nonnull=yes
     ;;
+
+*msys*)
+    WINDOWS=yes
+    MINGW=yes
+    platform=MinGW
+    portaudio=yes
+    portmidi=yes
+
+    # ASIO doesn't build yet with the autotools setup. We need to figure out how
+    # to make the final linking phase use g++
+    asio=yes
+
+    # externals are dynamically linked to pd.dll in their individual automake files
+    EXTERNAL_CFLAGS="-mms-bitfields"
+    EXTERNAL_LDFLAGS="-s -Wl,--enable-auto-import -no-undefined -lpd"
+    EXTERNAL_EXTENSION=dll
+
+    # workaround for rpl_malloc/rpl_realloc bug in autoconf when cross-compiling
+    ac_cv_func_malloc_0_nonnull=yes
+    ac_cv_func_realloc_0_nonnull=yes
+    ;;
+	
 *cygwin*)
     WINDOWS=yes
     CYGWIN=yes
@@ -140,6 +162,7 @@
 AM_CONDITIONAL(WINDOWS, test x$WINDOWS = xyes)
 AM_CONDITIONAL(CYGWIN, test x$CYGWIN = xyes)
 AM_CONDITIONAL(MINGW, test x$MINGW = xyes)
+AM_CONDITIONAL(MSYS, test x$MSYS = xyes)
 
 
 #########################################


More information about the Pd-dev mailing list