Skip to content

Commit

Permalink
wscript: enable main() function for Android port, which was forgotten…
Browse files Browse the repository at this point in the history
… after last refactoring
  • Loading branch information
a1batross committed Feb 1, 2025
1 parent 1b44d77 commit d997cc8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
9 changes: 7 additions & 2 deletions engine/wscript
Original file line number Diff line number Diff line change
Expand Up @@ -194,10 +194,15 @@ def build(bld):
source += bld.path.ant_glob('client/**/*.c')
libs += ['bzip2', 'MultiEmulator', 'opus', 'opusfile', 'vorbis', 'vorbisfile']

if not bld.env.LAUNCHER and bld.env.DEST_OS != 'android':
# Android port is linked differently
if bld.env.DEST_OS == 'android':
f = bld.shlib
install_path = bld.env.LIBDIR
defines += ['XASH_ENABLE_MAIN=1', 'XASH_SDLMAIN=1']
elif not bld.env.LAUNCHER:
f = bld.program
install_path = bld.env.BINDIR
defines += ['XASH_ENABLE_MAIN=1']
defines += ['XASH_ENABLE_MAIN=1']'
else:
f = bld.shlib
install_path = bld.env.LIBDIR
Expand Down
2 changes: 0 additions & 2 deletions wscript
Original file line number Diff line number Diff line change
Expand Up @@ -239,14 +239,12 @@ def configure(conf):
conf.options.GL4ES = True
conf.options.GLES3COMPAT = True
conf.options.GL = False
conf.define('XASH_SDLMAIN', 1)
elif conf.env.MAGX:
conf.options.SDL12 = True
conf.options.NO_VGUI = True
conf.options.GL = False
conf.options.LOW_MEMORY = 1
conf.options.NO_ASYNC_RESOLVE = True
conf.define('XASH_SDLMAIN', 1)
enforce_pic = False
elif conf.env.DEST_OS == 'nswitch':
conf.options.NO_VGUI = True
Expand Down

0 comments on commit d997cc8

Please sign in to comment.