From 077cf617adbf4d85cd1ec2c9145e0a1507071c06 Mon Sep 17 00:00:00 2001 From: octaspire Date: Sun, 20 Jan 2019 00:59:56 +0200 Subject: [PATCH] Fix (partially) Windows MinGW build --- .../octaspire/dern/octaspire_dern_config.h | 2 +- release/how-to-build/windows-mingw.sh | 22 +++++++++---------- release/octaspire-dern-amalgamated.c | 2 +- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/dev/include/octaspire/dern/octaspire_dern_config.h b/dev/include/octaspire/dern/octaspire_dern_config.h index a4b52d2..fcab469 100644 --- a/dev/include/octaspire/dern/octaspire_dern_config.h +++ b/dev/include/octaspire/dern/octaspire_dern_config.h @@ -19,7 +19,7 @@ limitations under the License. #define OCTASPIRE_DERN_CONFIG_VERSION_MAJOR "0" #define OCTASPIRE_DERN_CONFIG_VERSION_MINOR "479" -#define OCTASPIRE_DERN_CONFIG_VERSION_PATCH "0" +#define OCTASPIRE_DERN_CONFIG_VERSION_PATCH "1" #define OCTASPIRE_DERN_CONFIG_VERSION_STR "Octaspire Dern version " \ OCTASPIRE_DERN_CONFIG_VERSION_MAJOR "." \ diff --git a/release/how-to-build/windows-mingw.sh b/release/how-to-build/windows-mingw.sh index 5d40654..665061a 100755 --- a/release/how-to-build/windows-mingw.sh +++ b/release/how-to-build/windows-mingw.sh @@ -37,59 +37,59 @@ if [ "$2" = "--coverage" ]; then COVERAGE=$2; fi EXAMPLE_NAME="stand alone unit test runner" EXAMPLE_ERROR_HINT="Install $CC compiler?" EXAMPLE_SUCCESS_RUN="octaspire-dern-unit-test-runner.exe" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -DOCTASPIRE_DERN_AMALGAMATED_UNIT_TEST_IMPLEMENTATION -DOCTASPIRE_DERN_CONFIG_BINARY_PLUGINS $COVERAGE -I . octaspire-dern-amalgamated.c -lm -lKernel32 -o octaspire-dern-unit-test-runner +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -DOCTASPIRE_DERN_AMALGAMATED_UNIT_TEST_IMPLEMENTATION -DOCTASPIRE_DERN_CONFIG_BINARY_PLUGINS $COVERAGE -I . octaspire-dern-amalgamated.c -lm -lKernel32 -o octaspire-dern-unit-test-runner EXAMPLE_NAME="embedding example" EXAMPLE_ERROR_HINT="Install $CC compiler?" EXAMPLE_SUCCESS_RUN="embedding-example.exe" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -DOCTASPIRE_DERN_CONFIG_BINARY_PLUGINS -I . examples/embedding-example.c -lm -lKernel32 -o embedding-example +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -DOCTASPIRE_DERN_CONFIG_BINARY_PLUGINS -I . examples/embedding-example.c -lm -lKernel32 -o embedding-example EXAMPLE_NAME="implementation library for binary library example" EXAMPLE_ERROR_HINT="Install $CC compiler?" EXAMPLE_SUCCESS_RUN="" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -DOCTASPIRE_DERN_AMALGAMATED_IMPLEMENTATION -DOCTASPIRE_DERN_CONFIG_BINARY_PLUGINS octaspire-dern-amalgamated.c -lKernel32 -shared -Wl,--out-implib=imp.a +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -DOCTASPIRE_DERN_AMALGAMATED_IMPLEMENTATION -DOCTASPIRE_DERN_CONFIG_BINARY_PLUGINS octaspire-dern-amalgamated.c -lKernel32 -shared -Wl,--out-implib=imp.a EXAMPLE_NAME="binary library example" EXAMPLE_ERROR_HINT="Install $CC compiler?" EXAMPLE_SUCCESS_RUN="octaspire-dern-repl.exe examples\\use-mylib.dern" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -fPIC -shared -I . -o libmylib.dll examples/mylib.c -L . imp.a +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -fPIC -shared -I . -o libmylib.dll examples/mylib.c -L . imp.a EXAMPLE_NAME="interactive Dern REPL" EXAMPLE_ERROR_HINT="Install $CC compiler?" EXAMPLE_SUCCESS_RUN="octaspire-dern-repl.exe" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -DOCTASPIRE_DERN_AMALGAMATED_REPL_IMPLEMENTATION -DOCTASPIRE_DERN_CONFIG_BINARY_PLUGINS -I . octaspire-dern-amalgamated.c -lm -lKernel32 -o octaspire-dern-repl +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -DOCTASPIRE_DERN_AMALGAMATED_REPL_IMPLEMENTATION -DOCTASPIRE_DERN_CONFIG_BINARY_PLUGINS -I . octaspire-dern-amalgamated.c -lm -lKernel32 -o octaspire-dern-repl EXAMPLE_NAME="Dern socket plugin" EXAMPLE_ERROR_HINT="Install $CC compiler?" EXAMPLE_SUCCESS_RUN="octaspire-dern-repl examples\\irc-client.dern" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -fPIC -shared -I . -o libdern_socket.dll plugins/dern_socket.c -lws2_32 -L . imp.a +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -fPIC -shared -I . -o libdern_socket.dll plugins/dern_socket.c -lws2_32 -L . imp.a EXAMPLE_NAME="Dern dir plugin" EXAMPLE_ERROR_HINT="Install $CC compiler?" EXAMPLE_SUCCESS_RUN="octaspire-dern-repl examples\\dern-dir-example.dern" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -fPIC -shared -I . -shared -o libdern_dir.dll plugins/dern_dir.c -lKernel32 -L . imp.a +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -fPIC -shared -I . -shared -o libdern_dir.dll plugins/dern_dir.c -lKernel32 -L . imp.a EXAMPLE_NAME="Dern easing plugin" EXAMPLE_ERROR_HINT="Install $CC compiler?" EXAMPLE_SUCCESS_RUN="octaspire-dern-repl examples\\dern-easing-example.dern" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -fPIC -shared -I . -shared -o libdern_easing.dll plugins/dern_easing.c -L . imp.a +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -fPIC -shared -I . -shared -o libdern_easing.dll plugins/dern_easing.c -L . imp.a EXAMPLE_NAME="Dern animation plugin" EXAMPLE_ERROR_HINT="Install $CC compiler?" EXAMPLE_SUCCESS_RUN="octaspire-dern-repl examples\\dern-animation-example.dern" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -fPIC -shared -I . -shared -o libdern_animation.dll plugins/dern_animation.c -L . imp.a +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -fPIC -shared -I . -shared -o libdern_animation.dll plugins/dern_animation.c -L . imp.a @@ -101,7 +101,7 @@ read -rd '' EXAMPLE_ERROR_HINT << EOF d) Run command: how-to-build/windows.sh EOF EXAMPLE_SUCCESS_RUN="octaspire-dern-repl examples\\dern-ncurses-example.dern" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -fPIC -I . -shared -o libdern_ncurses.dll plugins/dern_ncurses.c -L . -lpdcurses imp.a +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -fPIC -I . -shared -o libdern_ncurses.dll plugins/dern_ncurses.c -L . -lpdcurses imp.a @@ -121,5 +121,5 @@ read -rd '' EXAMPLE_ERROR_HINT << EOF cp SDL2_ttf-2.0.14/i686-w64-mingw32/bin/*.dll . EOF EXAMPLE_SUCCESS_RUN="octaspire-dern-repl examples\\dern-sdl2-example.dern" -echoAndRun "$CC" -O2 -std=c99 -Wall -Wextra -fPIC -shared -DOCTASPIRE_DERN_SDL2_PLUGIN_USE_SDL_IMAGE_LIBRARY -DOCTASPIRE_DERN_SDL2_PLUGIN_USE_SDL_MIXER_LIBRARY -DOCTASPIRE_DERN_SDL2_PLUGIN_USE_SDL_TTF_LIBRARY -Dmain=SDL_main -I . -I SDL2-2.0.7/i686-w64-mingw32/include/SDL2 -I SDL2_image-2.0.2/i686-w64-mingw32/include/SDL2 -I SDL2_mixer-2.0.2/i686-w64-mingw32/include/SDL2 -I SDL2_ttf-2.0.14/i686-w64-mingw32/include/SDL2 -o libdern_sdl2.dll plugins/dern_sdl2.c -L . -L SDL2-2.0.7/i686-w64-mingw32/lib -L SDL2_image-2.0.2/i686-w64-mingw32/lib -L SDL2_mixer-2.0.2/i686-w64-mingw32/lib -L SDL2_ttf-2.0.14/i686-w64-mingw32/lib imp.a -lSDL2main -lSDL2 libSDL2_image.a -lSDL2_mixer -lSDL2_ttf +echoAndRun "$CC" -O2 -std=gnu99 -Wall -Wextra -fPIC -shared -DOCTASPIRE_DERN_SDL2_PLUGIN_USE_SDL_IMAGE_LIBRARY -DOCTASPIRE_DERN_SDL2_PLUGIN_USE_SDL_MIXER_LIBRARY -DOCTASPIRE_DERN_SDL2_PLUGIN_USE_SDL_TTF_LIBRARY -Dmain=SDL_main -I . -I SDL2-2.0.7/i686-w64-mingw32/include/SDL2 -I SDL2_image-2.0.2/i686-w64-mingw32/include/SDL2 -I SDL2_mixer-2.0.2/i686-w64-mingw32/include/SDL2 -I SDL2_ttf-2.0.14/i686-w64-mingw32/include/SDL2 -o libdern_sdl2.dll plugins/dern_sdl2.c -L . -L SDL2-2.0.7/i686-w64-mingw32/lib -L SDL2_image-2.0.2/i686-w64-mingw32/lib -L SDL2_mixer-2.0.2/i686-w64-mingw32/lib -L SDL2_ttf-2.0.14/i686-w64-mingw32/lib imp.a -lSDL2main -lSDL2 libSDL2_image.a -lSDL2_mixer -lSDL2_ttf diff --git a/release/octaspire-dern-amalgamated.c b/release/octaspire-dern-amalgamated.c index 2e05cd3..f528065 100644 --- a/release/octaspire-dern-amalgamated.c +++ b/release/octaspire-dern-amalgamated.c @@ -26337,7 +26337,7 @@ limitations under the License. #define OCTASPIRE_DERN_CONFIG_VERSION_MAJOR "0" #define OCTASPIRE_DERN_CONFIG_VERSION_MINOR "479" -#define OCTASPIRE_DERN_CONFIG_VERSION_PATCH "0" +#define OCTASPIRE_DERN_CONFIG_VERSION_PATCH "1" #define OCTASPIRE_DERN_CONFIG_VERSION_STR "Octaspire Dern version " \ OCTASPIRE_DERN_CONFIG_VERSION_MAJOR "." \ -- 2.45.2