pidgin/plugins/meson.build

Tue, 22 Dec 2020 00:19:36 -0600

author
Elliott Sales de Andrade <quantum.analyst@gmail.com>
date
Tue, 22 Dec 2020 00:19:36 -0600
changeset 40669
48dfed6f4f1f
parent 40581
0670e82f1f58
child 40994
1eb6d260980d
permissions
-rw-r--r--

Fix Windows builds and tests

* Make math library optional.
As the comment says, it should be optional on Windows and Haiku, but the check defaults to required.
* Don't make `unistd.h` required.
* Disable transparency plugin build as it's very busted.
* Add missing headers to fix compile on Windows.
* Use a fixed pref key for test plugin loading instead of `TEST_DATA_DIR`.
The latter is an absolute path, and thus unsuitable as a preference key, since it will not start with `/` on Windows.
* Add a missing pref initialization on Windows.

Testing Done:
Compiled and run tests on Windows.

Reviewed at https://reviews.imfreedom.org/r/308/

subdir('disco')
subdir('gestures')
subdir('xmppconsole')

if PLUGINS
	gtkbuddynote = library('gtkbuddynote', 'gtkbuddynote.c',
	    dependencies : [libpurple_dep, libpidgin_dep, glib],
	    name_prefix : '',
	    install : true, install_dir : PIDGIN_PLUGINDIR)

	iconaway = library('iconaway', 'iconaway.c',
	    dependencies : [libpurple_dep, libpidgin_dep, glib],
	    name_prefix : '',
	    install : true, install_dir : PIDGIN_PLUGINDIR)

	notify = library('notify', 'notify.c',
	    dependencies : [libpurple_dep, libpidgin_dep, glib],
	    name_prefix : '',
	    build_by_default: false,
	    install : false, install_dir : PIDGIN_PLUGINDIR)

	relnot = library('relnot', 'relnot.c',
	    dependencies : [libpurple_dep, libpidgin_dep, libsoup, glib],
	    name_prefix : '',
	    install : true, install_dir : PIDGIN_PLUGINDIR)

	spellchk = library('spellchk', 'spellchk.c',
	    dependencies : [libpurple_dep, libpidgin_dep, glib],
	    name_prefix : '',
	    build_by_default: false,
	    install : false, install_dir : PIDGIN_PLUGINDIR)

	if IS_WIN32
		transparency = library('transparency', 'transparency.c',
			dependencies : [libpurple_dep, libpidgin_dep, glib],
			name_prefix : '',
			build_by_default : false,
			install : false, install_dir : PIDGIN_PLUGINDIR)
	endif

	if enable_unity
		unity = library('unity', 'unity.c',
		    dependencies : [UNITY, libpurple_dep, libpidgin_dep, glib],
		    name_prefix : '',
		    install : true, install_dir : PIDGIN_PLUGINDIR)
	endif

endif # PLUGINS

mercurial