Had to bring back the static options so that meson actually builds it as static.
This commit is contained in:
parent
c14e244084
commit
514bfec0ea
2 changed files with 19 additions and 7 deletions
10
Makefile
10
Makefile
|
|
@ -41,20 +41,20 @@ test: build
|
||||||
|
|
||||||
run: build test
|
run: build test
|
||||||
ifeq '$(OS)' 'Windows_NT'
|
ifeq '$(OS)' 'Windows_NT'
|
||||||
powershell "cp ./builddir/zedcaster.exe ."
|
powershell "cp ./builddir/under_the_dome.exe ."
|
||||||
./zedcaster
|
./under_the_dome
|
||||||
else
|
else
|
||||||
./builddir/zedcaster
|
./builddir/under_the_dome
|
||||||
endif
|
endif
|
||||||
|
|
||||||
debug: build
|
debug: build
|
||||||
gdb --nx -x .gdbinit --ex run --args builddir/runtests
|
gdb --nx -x .gdbinit --ex run --args builddir/runtests
|
||||||
|
|
||||||
debug_run: build
|
debug_run: build
|
||||||
gdb --nx -x .gdbinit --batch --ex run --ex bt --ex q --args builddir/zedcaster
|
gdb --nx -x .gdbinit --batch --ex run --ex bt --ex q --args builddir/under_the_dome
|
||||||
|
|
||||||
debug_walk: build test
|
debug_walk: build test
|
||||||
gdb --nx -x .gdbinit --batch --ex run --ex bt --ex q --args builddir/zedcaster t
|
gdb --nx -x .gdbinit --batch --ex run --ex bt --ex q --args builddir/under_the_dome t
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
meson compile --clean -C builddir
|
meson compile --clean -C builddir
|
||||||
|
|
|
||||||
16
meson.build
16
meson.build
|
|
@ -1,5 +1,5 @@
|
||||||
|
|
||||||
project('raycaster', 'cpp',
|
project('under_the_dome', 'cpp',
|
||||||
version: '0.1.0',
|
version: '0.1.0',
|
||||||
default_options: [
|
default_options: [
|
||||||
'cpp_std=c++23',
|
'cpp_std=c++23',
|
||||||
|
|
@ -22,6 +22,14 @@ cc = meson.get_compiler('cpp')
|
||||||
dependencies = []
|
dependencies = []
|
||||||
|
|
||||||
if build_machine.system() == 'windows'
|
if build_machine.system() == 'windows'
|
||||||
|
add_global_link_arguments(
|
||||||
|
'-static-libgcc',
|
||||||
|
'-static-libstdc++',
|
||||||
|
'-static',
|
||||||
|
'-flto',
|
||||||
|
language: 'cpp',
|
||||||
|
)
|
||||||
|
|
||||||
sfml_main = subproject('sfml').get_variable('sfml_main_dep')
|
sfml_main = subproject('sfml').get_variable('sfml_main_dep')
|
||||||
opengl32 = cc.find_library('opengl32', required: true)
|
opengl32 = cc.find_library('opengl32', required: true)
|
||||||
winmm = cc.find_library('winmm', required: true)
|
winmm = cc.find_library('winmm', required: true)
|
||||||
|
|
@ -33,6 +41,10 @@ if build_machine.system() == 'windows'
|
||||||
exe_defaults += ['werror=true']
|
exe_defaults += ['werror=true']
|
||||||
|
|
||||||
elif build_machine.system() == 'darwin'
|
elif build_machine.system() == 'darwin'
|
||||||
|
add_global_link_arguments(
|
||||||
|
language: 'cpp',
|
||||||
|
)
|
||||||
|
|
||||||
opengl = dependency('OpenGL')
|
opengl = dependency('OpenGL')
|
||||||
corefoundation = dependency('CoreFoundation')
|
corefoundation = dependency('CoreFoundation')
|
||||||
carbon = dependency('Carbon')
|
carbon = dependency('Carbon')
|
||||||
|
|
@ -97,7 +109,7 @@ executable('runtests', sources + tests,
|
||||||
override_options: exe_defaults,
|
override_options: exe_defaults,
|
||||||
dependencies: dependencies + [catch2])
|
dependencies: dependencies + [catch2])
|
||||||
|
|
||||||
executable('zedcaster',
|
executable('under_the_dome',
|
||||||
[ 'src/main.cpp' ],
|
[ 'src/main.cpp' ],
|
||||||
cpp_args: cpp_args,
|
cpp_args: cpp_args,
|
||||||
link_args: link_args,
|
link_args: link_args,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue