summaryrefslogtreecommitdiffhomepage
path: root/patches
diff options
context:
space:
mode:
Diffstat (limited to 'patches')
-rw-r--r--patches/smallbasic.local.patch22
-rw-r--r--patches/smallbasic/dlopen.patch12
-rw-r--r--patches/smallbasic_pre.local.patch33
3 files changed, 45 insertions, 22 deletions
diff --git a/patches/smallbasic.local.patch b/patches/smallbasic.local.patch
deleted file mode 100644
index c12262fb..00000000
--- a/patches/smallbasic.local.patch
+++ /dev/null
@@ -1,22 +0,0 @@
---- SmallBASIC/configure.ac.orig 2018-02-04 10:05:56.100000000 +0000
-+++ SmallBASIC/configure.ac 2018-02-08 11:39:39.740000000 +0000
-@@ -117,7 +117,7 @@
-
- if test "${have_pcre}" = "yes" ; then
- AC_DEFINE(USE_PCRE, 1, [match.c used with libpcre.])
-- PACKAGE_LIBS="${PACKAGE_LIBS} `pcre-config --libs`"
-+ PACKAGE_LIBS="${PACKAGE_LIBS} ${PCRE_LIBS}"
- fi
- }
-
---- SmallBASIC/src/platform/console/main.c.orig 2018-02-04 10:05:56.108000000 +0000
-+++ SmallBASIC/src/platform/console/main.c 2018-02-08 11:39:11.172000000 +0000
-@@ -262,7 +262,7 @@
- return 1;
- }
-
--#if defined(__GNUC__) && !defined(__MACH__) && !defined(_Win32)
-+#if defined(__GLIBC__) && !defined(__MACH__) && !defined(_Win32)
- // for analysing excessive malloc calls using kdbg
- extern void *__libc_malloc(size_t size);
- void *malloc(size_t size) {
diff --git a/patches/smallbasic/dlopen.patch b/patches/smallbasic/dlopen.patch
new file mode 100644
index 00000000..8bc3a5b1
--- /dev/null
+++ b/patches/smallbasic/dlopen.patch
@@ -0,0 +1,12 @@
+diff -ru SmallBASIC.orig/src/common/extlib.c SmallBASIC/src/common/extlib.c
+--- SmallBASIC.orig/src/common/extlib.c 2018-08-18 16:06:03.103804486 +0200
++++ SmallBASIC/src/common/extlib.c 2018-08-18 16:13:04.390441908 +0200
+@@ -22,7 +22,7 @@
+ #define WIN_EXTLIB
+ #define LIB_EXT ".dll"
+ #define DEFAULT_PATH "c:/sbasic/lib"
+-#elif defined(__linux__) && defined(_UnixOS)
++#elif defined(__linux__) || defined(__midipix__) && defined(_UnixOS)
+ #include <dlfcn.h>
+ #define LNX_EXTLIB
+ #define LIB_EXT ".so"
diff --git a/patches/smallbasic_pre.local.patch b/patches/smallbasic_pre.local.patch
new file mode 100644
index 00000000..63e85d23
--- /dev/null
+++ b/patches/smallbasic_pre.local.patch
@@ -0,0 +1,33 @@
+diff -ru SmallBASIC.orig/configure.ac SmallBASIC/configure.ac
+--- SmallBASIC.orig/configure.ac 2018-08-18 15:58:59.300508539 +0200
++++ SmallBASIC/configure.ac 2018-08-18 16:04:05.394415143 +0200
+@@ -117,7 +117,7 @@
+
+ if test "${have_pcre}" = "yes" ; then
+ AC_DEFINE(USE_PCRE, 1, [match.c used with libpcre.])
+- PACKAGE_LIBS="${PACKAGE_LIBS} `pcre-config --libs`"
++ PACKAGE_LIBS="${PACKAGE_LIBS} ${PCRE_LIBS}"
+ fi
+ }
+
+@@ -325,7 +325,7 @@
+ checkProfiling
+ checkForWindows
+
+-CFLAGS="${CFLAGS} -std=gnu11"
++CFLAGS="${CFLAGS} -std=gnu99"
+ PACKAGE_CFLAGS="${PACKAGE_CFLAGS} -Wall -Wno-unused-result"
+ BUILD_DATE=`date +"%a, %d %b %Y"`
+ AC_DEFINE_UNQUOTED([BUILD_DATE],["$BUILD_DATE"],[Build date])
+diff -ru SmallBASIC.orig/src/platform/console/main.cpp SmallBASIC/src/platform/console/main.cpp
+--- SmallBASIC.orig/src/platform/console/main.cpp 2018-08-18 15:58:59.324509172 +0200
++++ SmallBASIC/src/platform/console/main.cpp 2018-08-18 16:04:21.506628434 +0200
+@@ -332,7 +332,7 @@
+ return gsb_last_error ? gsb_last_line : 0;
+ }
+
+-#if defined(__GNUC__) && !defined(__MACH__) && !defined(_Win32)
++#if defined(__GLIBC__) && !defined(__MACH__) && !defined(_Win32)
+ // for analysing excessive malloc calls using kdbg
+ extern "C" void *__libc_malloc(size_t size);
+ void *malloc(size_t size) {