Created
November 17, 2025 16:37
-
-
Save KokoseiJ/a6f476f1ee8865fe810a3d8cfe757ca1 to your computer and use it in GitHub Desktop.
Fix for ardour-build-tools/x-mingw.sh for preparing Ardour mingw build chain
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/x-mingw.sh b/x-mingw.sh | |
| index 45d5a1f..23b1b5a 100755 | |
| --- a/x-mingw.sh | |
| +++ b/x-mingw.sh | |
| @@ -40,8 +40,8 @@ | |
| ### influential environment variables | |
| -: ${MAKEFLAGS=-j4} | |
| -: ${STACKCFLAGS="-O2 -g"} | |
| +: ${MAKEFLAGS=-j15} | |
| +: ${STACKCFLAGS="-O2 -Wno-incompatible-pointer-types -Wno-implicit-function-declaration"} | |
| : ${SRCDIR=/var/tmp/winsrc} # source-code .tgz cache | |
| : ${TMPDIR=/var/tmp} # package is built (and zipped) here. | |
| @@ -220,8 +220,8 @@ windres = '/usr/bin/${XPREFIX}-windres' | |
| pkgconfig = '/usr/bin/pkg-config' | |
| [properties] | |
| -c_args = ['-I${PREFIX}/include', '-O2', '-mstackrealign', '-Werror=format=0'] | |
| -cpp_args = ['-I${PREFIX}/include', '-O2', '-mstackrealign', '-std=gnu++11'] | |
| +c_args = ['-I${PREFIX}/include', '-O2', '-mstackrealign', '-Werror=format=0', '-Wno-incompatible-pointer-types', '-Wno-int-conversion'] | |
| +cpp_args = ['-I${PREFIX}/include', '-O2', '-mstackrealign', '-std=gnu++11', '-Wno-incompatible-pointer-types', '-Wno-int-conversion'] | |
| c_link_args = ['-L${PREFIX}/lib'] | |
| cpp_link_args = ['-L${PREFIX}/lib'] | |
| #sys_root = '$PREFIX' | |
| @@ -317,6 +317,79 @@ EOF | |
| autoconfbuild | |
| src termcap-1.3.1 tar.gz http://ftpmirror.gnu.org/termcap/termcap-1.3.1.tar.gz | |
| +patch -p1 <<EOF | |
| +diff -ru a/termcap.c b/termcap.c | |
| +--- a/termcap.c 2002-02-25 17:59:21.000000000 +0000 | |
| ++++ b/termcap.c 2025-11-17 13:48:18.252901051 +0000 | |
| +@@ -22,28 +22,8 @@ | |
| + #include <config.h> | |
| + #endif | |
| + | |
| +-#ifdef emacs | |
| +- | |
| +-#include <lisp.h> /* xmalloc is here */ | |
| +-/* Get the O_* definitions for open et al. */ | |
| +-#include <sys/file.h> | |
| +-#ifdef HAVE_FCNTL_H | |
| +-#include <fcntl.h> | |
| +-#endif | |
| +-#ifdef HAVE_UNISTD_H | |
| +-#include <unistd.h> | |
| +-#endif | |
| +- | |
| +-#else /* not emacs */ | |
| +- | |
| +-#ifdef STDC_HEADERS | |
| + #include <stdlib.h> | |
| + #include <string.h> | |
| +-#else | |
| +-char *getenv (); | |
| +-char *malloc (); | |
| +-char *realloc (); | |
| +-#endif | |
| + | |
| + /* Do this after the include, in case string.h prototypes bcopy. */ | |
| + #if (defined(HAVE_STRING_H) || defined(STDC_HEADERS)) && !defined(bcopy) | |
| +@@ -57,8 +37,6 @@ | |
| + #include <fcntl.h> | |
| + #endif | |
| + | |
| +-#endif /* not emacs */ | |
| +- | |
| + #ifndef NULL | |
| + #define NULL (char *) 0 | |
| + #endif | |
| +diff -ru a/tparam.c b/tparam.c | |
| +--- a/tparam.c 2002-02-25 17:37:24.000000000 +0000 | |
| ++++ b/tparam.c 2025-11-17 13:49:32.756905362 +0000 | |
| +@@ -21,25 +21,15 @@ | |
| + #include <config.h> | |
| + #endif | |
| + | |
| +-#ifdef emacs | |
| +-#include "lisp.h" /* for xmalloc */ | |
| +-#else | |
| +- | |
| +-#ifdef STDC_HEADERS | |
| + #include <stdlib.h> | |
| + #include <string.h> | |
| +-#else | |
| +-char *malloc (); | |
| +-char *realloc (); | |
| +-#endif | |
| ++#include <unistd.h> | |
| + | |
| + /* Do this after the include, in case string.h prototypes bcopy. */ | |
| + #if (defined(HAVE_STRING_H) || defined(STDC_HEADERS)) && !defined(bcopy) | |
| + #define bcopy(s, d, n) memcpy ((d), (s), (n)) | |
| + #endif | |
| + | |
| +-#endif /* not emacs */ | |
| +- | |
| + #ifndef NULL | |
| + #define NULL (char *) 0 | |
| + #endif | |
| +EOF | |
| autoconfconf | |
| make install CC=${XPREFIX}-gcc AR=${XPREFIX}-ar RANLIB=${XPREFIX}-ranlib | |
| @@ -706,7 +779,7 @@ MAKEFLAGS= \ | |
| # alternative: https://github.com/chriskohlhoff/asio | |
| rm -f ${PREFIX}/include/pa_asio.h ${PREFIX}/include/portaudio.h ${PREFIX}/include/asio.h | |
| if test ! -d ${SRCDIR}/soundfind.git.reference; then | |
| - git clone --mirror git://github.com/aardvarkk/soundfind.git ${SRCDIR}/soundfind.git.reference | |
| + git clone --mirror https://github.com/danieldram/soundfind ${SRCDIR}/soundfind.git.reference | |
| fi | |
| cd ${BUILDD} | |
| #git clone --reference ${SRCDIR}/soundfind.git.reference --depth 1 git://github.com/aardvarkk/soundfind.git || true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment