Skip to content

Commit

Permalink
meson: add HOST_MACOS
Browse files Browse the repository at this point in the history
Reported-by: Jaimos Skriletz <jaimosskriletz@gmail.com>
Signed-off-by: Matt Jolly <kangie@gentoo.org>
  • Loading branch information
Kangie committed Oct 28, 2024
1 parent 1067a72 commit ad19eae
Show file tree
Hide file tree
Showing 2 changed files with 76 additions and 61 deletions.
133 changes: 72 additions & 61 deletions libs/meson.build
Original file line number Diff line number Diff line change
@@ -1,66 +1,77 @@
libfvwm3_sources = files(
'BidiJoin.c',
'Bindings.c',
'ClientMsg.c',
'ColorUtils.c',
'Colorset.c',
'CombineChars.c',
'Cursor.c',
'Event.c',
'FBidi.c',
'FEvent.c',
'FGettext.c',
'FImage.c',
'FRender.c',
'FRenderInit.c',
'FScreen.c',
'FShape.c',
'FTips.c',
'Fft.c',
'Ficonv.c',
'Flocale.c',
'FlocaleCharset.c',
'Grab.c',
'Graphics.c',
'Module.c',
'Parse.c',
'Picture.c',
'PictureBase.c',
'PictureGraphics.c',
'PictureImageLoader.c',
'PictureUtils.c',
'Rectangles.c',
'Strings.c',
'System.c',
'Target.c',
'WinMagic.c',
'XError.c',
'XResource.c',
'cJSON.c',
'charmap.c',
'envvar.c',
'fio.c',
'flist.c',
'fqueue.c',
'fsm.c',
'fvwmlib3.c',
'fvwmrect.c',
'fvwmsignal.c',
'getpwuid.c',
'gravity.c',
'log.c',
'modifiers.c',
'safemalloc.c',
'setpgrp.c',
'strtonum.c',
'timeout.c',
'wcontext.c',
'wild.c',
)

string_sources = files(
'strlcat.c',
'strlcpy.c',
)

# We don't build the string sources on macOS
# We probably could check for target_system, but nobody is cross-compiling _to_ macOS
if not (host_machine.system() == 'darwin')
libfvwm3_sources += string_sources
endif

libfvwm3 = static_library(
'fvwm3',
sources: [
'BidiJoin.c',
'Bindings.c',
'ClientMsg.c',
'ColorUtils.c',
'Colorset.c',
'CombineChars.c',
'Cursor.c',
'Event.c',
'FBidi.c',
'FEvent.c',
'FGettext.c',
'FImage.c',
'FRender.c',
'FRenderInit.c',
'FScreen.c',
'FShape.c',
'FTips.c',
'Fft.c',
'Ficonv.c',
'Flocale.c',
'FlocaleCharset.c',
'Grab.c',
'Graphics.c',
'Module.c',
'Parse.c',
'Picture.c',
'PictureBase.c',
'PictureGraphics.c',
'PictureImageLoader.c',
'PictureUtils.c',
'Rectangles.c',
'Strings.c',
'System.c',
'Target.c',
'WinMagic.c',
'XError.c',
'XResource.c',
'cJSON.c',
'charmap.c',
'envvar.c',
'fio.c',
'flist.c',
'fqueue.c',
'fsm.c',
'fvwmlib3.c',
'fvwmrect.c',
'fvwmsignal.c',
'getpwuid.c',
'gravity.c',
'log.c',
'modifiers.c',
'safemalloc.c',
'setpgrp.c',
'strlcat.c',
'strlcpy.c',
'strtonum.c',
'timeout.c',
'wcontext.c',
'wild.c',
],
sources: libfvwm3_sources,
include_directories: includedirs,
dependencies: all_found_deps,
install: false,
Expand Down
4 changes: 4 additions & 0 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@ if host_machine.endian() == 'big'
conf.set('WORDS_BIGENDIAN', true)
endif

if host_machine.system() == 'darwin'
conf.set10('HOST_MACOS', true)
endif

# Set static configuration.
conf.set_quoted('VERSION', meson.project_version())
conf.set_quoted('VERSIONINFO', fvwm_vcs_versioninfo)
Expand Down

0 comments on commit ad19eae

Please sign in to comment.