Skip to content
Snippets Groups Projects
Commit b5aa1e87 authored by Dmitry Marakasov's avatar Dmitry Marakasov
Browse files

games/taisei: remove USE_GCC and clean up dependency handling

parent b1fa93c1
No related branches found
No related tags found
No related merge requests found
......@@ -27,9 +27,8 @@ USES= compiler:c11 desktop-file-utils meson pkgconfig \
SHEBANG_FILES= scripts/*.py
MESON_ARGS= -Dversion_fallback=${PORTVERSION} -Db_lto=false
MESON_ARGS+= --wrap-mode=nofallback
#MESON_ARGS+= -DOPENSSLLIB="${OPENSSLLIB}" -DOPENSSLINC="${OPENSSLINC}"
MESON_ARGS+= -DOPENSSLLIB="${OPENSSLLIB}" -DOPENSSLINC="${OPENSSLINC}"
USE_SDL= sdl2 ttf2 mixer2
#USE_GCC= yes
PORTDOCS= *
PORTDATA= *
......
* Make all depends required, thus deterministic.
* Redefine libcrypto dependency - there are no means of detection for
system OpenSSL on FreeBSD (e.g. no pkgconfig file), so we need to
point the build right to the library. Additionally, since OpenSSL
may also come from ports, respect OPENSSLLIB passed from the framework
to pick the right library. This works with system OpenSSL, _may_
work with OpenSSL from ports and will probably _not_ work with
OpenSSL form ports where OPENSSL_DEFAULT is set to base, as it will
still pick includes from /usr/local.
* Make sure to never detect gamemode which is missing on FreeBSD anyway.
--- meson.build.orig 2021-04-30 18:54:50 UTC
+++ meson.build
@@ -151,8 +151,9 @@ dep_webpdecoder = dependency('libwebpdecoder', version
dep_zip = dependency('libzip', version : '>=1.2', required : false, static : static, fallback : ['libzip', 'libzip_dep'])
@@ -142,19 +142,19 @@ endif
static = get_option('static') or ['emscripten', 'nx'].contains(host_machine.system())
dep_freetype = dependency('freetype2', required : true, static : static, fallback : ['freetype', 'freetype_dep'])
-dep_opusfile = dependency('opusfile', required : false, static : static, fallback : ['opusfile', 'opusfile_dep'])
+dep_opusfile = dependency('opusfile', required : true, static : static, fallback : ['opusfile', 'opusfile_dep'])
dep_png = dependency('libpng', version : '>=1.5', required : true, static : static, fallback : ['libpng', 'png_dep'])
dep_sdl2 = dependency('sdl2', version : '>=2.0.6', required : true, static : static, fallback : ['sdl2', 'sdl2_dep'])
-dep_sdl2_mixer = dependency('SDL2_mixer', version : '>=2.0.4', required : false, static : static, fallback : ['sdl2_mixer', 'sdl2_mixer_dep'])
+dep_sdl2_mixer = dependency('SDL2_mixer', version : '>=2.0.4', required : true, static : static, fallback : ['sdl2_mixer', 'sdl2_mixer_dep'])
dep_webp = dependency('libwebp', version : '>=0.5', required : true, static : static, fallback : ['libwebp', 'webpdecoder_dep'])
-dep_webpdecoder = dependency('libwebpdecoder', version : '>=0.5', required : false, static : static)
-dep_zip = dependency('libzip', version : '>=1.2', required : false, static : static, fallback : ['libzip', 'libzip_dep'])
+dep_webpdecoder = dependency('libwebpdecoder', version : '>=0.5', required : true, static : static)
+dep_zip = dependency('libzip', version : '>=1.2', required : true, static : static, fallback : ['libzip', 'libzip_dep'])
dep_zlib = dependency('zlib', required : true, static : static, fallback : ['zlib', 'zlib_dep'])
dep_cglm = dependency('cglm', version : '>=0.7.8', required : true, static : static, fallback : ['cglm', 'cglm_dep'])
-dep_crypto = dependency('libcrypto', required : false, static : static)
-dep_gamemode = dependency('gamemode', required : false, static : static)
+dep_crypto = cc.find_library('crypto', required : true) # does not respect OPENSSLLIB/OPENSSLINC
+#dep_crypto = declare_dependency(link_with:shared_library(get_option('OPENSSLLIB') / 'libcrypto.so'), include_directories:include_directories(get_option('OPENSSLINC'))) # does not work in modern meson
+dep_gamemode = dependency('', required : false) # no gamemode on freebsd
+dep_crypto = cc.find_library('crypto', dirs : get_option('OPENSSLLIB'), required : true)
+dep_gamemode = dependency('', required : false)
-dep_m = cc.find_library('m', required : false)
+dep_m = cc.find_library('m', required : true)
dep_m = cc.find_library('m', required : false)
dep_glad = subproject('glad').get_variable('glad_dep')
--- meson_options.txt.orig 2021-04-30 18:54:50 UTC
+++ meson_options.txt
@@ -197,3 +197,5 @@ option(
value : true,
description : 'Allow use of some GNU C extensions (if supported by compiler)'
)
+
+option('OPENSSLLIB', type : 'string')
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment