From 16e6d1511e03741af48fb6cad1247117de7adfff Mon Sep 17 00:00:00 2001 From: Leland Lucius Date: Tue, 7 Apr 2015 22:11:26 -0500 Subject: [PATCH] Updates to use new Nyquist v3.09. --- lib-src/libnyquist/xlisp.patch | 50 ++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 lib-src/libnyquist/xlisp.patch diff --git a/lib-src/libnyquist/xlisp.patch b/lib-src/libnyquist/xlisp.patch new file mode 100644 index 000000000..ff2892456 --- /dev/null +++ b/lib-src/libnyquist/xlisp.patch @@ -0,0 +1,50 @@ +diff -ruN nyquist/xlisp/security.c ../audacity/lib-src/libnyquist/nyquist/xlisp/security.c +--- nyquist/xlisp/security.c 2015-03-05 03:00:46.520295100 -0600 ++++ nyquist/xlisp/security.c 2015-03-05 03:08:57.526379100 -0600 +@@ -4,7 +4,9 @@ + */ + + #include ++#ifndef WIN32 + #include ++#endif + #include + #include + +@@ -56,13 +58,13 @@ + int ok_to_open(const char *filename, const char *mode) + { + char fullname[STRMAX]; +- if (index(mode, 'r')) { /* asking for read permission */ ++ if (strchr(mode, 'r')) { /* asking for read permission */ + if (secure_read_path) { /* filename must be in path */ + find_full_path(filename, fullname); + if (!in_tree(fullname, secure_read_path)) return FALSE; + } + } +- if (index(mode, 'w')) { /* asking for write permission */ ++ if (strchr(mode, 'w')) { /* asking for write permission */ + if (safe_write_path) { /* filename must be in path */ + find_full_path(filename, fullname); + if (!in_tree(fullname, safe_write_path)) return FALSE; +@@ -98,7 +100,7 @@ + /* if windows, replace \ with / to simplify the rest */ + char *loc = fullname; + if (os_pathchar != '/') { +- while ((loc = index(loc, os_pathchar))) { ++ while ((loc = strchr(loc, os_pathchar))) { + *loc = '/'; + } + } +diff -ruN nyquist/xlisp/xlisp.h ../audacity/lib-src/libnyquist/nyquist/xlisp/xlisp.h +--- nyquist/xlisp/xlisp.h 2015-03-05 03:00:46.507294400 -0600 ++++ nyquist/xlisp/xlisp.h 2015-03-05 03:10:39.273198700 -0600 +@@ -40,6 +40,8 @@ + #define OFFTYPE long + #define SAVERESTORE + #define XL_LITTLE_ENDIAN ++#define _setjmp setjmp ++#define _longjmp longjmp + #endif + + /* for the Turbo C compiler - MS-DOS, large model */