Commit 4d88361d authored by Jehan's avatar Jehan
Browse files

Adding various link-time dependencies.

This fixes building glib for Android where builds were failing with
various 'undefined reference' errors.
parent e1eaea3e
Pipeline #14980 passed with stages
in 8 minutes and 29 seconds
......@@ -782,7 +782,7 @@ libgio = library('gio-2.0',
# '$(gio_win32_res_ldflag)',
dependencies : [libz_dep, libdl_dep, libmount_dep, libglib_dep,
libgobject_dep, libgmodule_dep, selinux_dep, xattr_dep,
platform_deps, network_libs],
platform_deps, network_libs, libffi_dep],
c_args : gio_c_args,
objc_args : gio_c_args,
# intl.lib is not compatible with SAFESEH
......@@ -881,27 +881,30 @@ executable('gio', gio_tool_sources,
c_args : gio_c_args,
# intl.lib is not compatible with SAFESEH
link_args : noseh_link_args,
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep])
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep,
libffi_dep, libiconv, libz_dep])
executable('gresource', 'gresource-tool.c',
install : true,
# intl.lib is not compatible with SAFESEH
link_args : noseh_link_args,
dependencies : [libelf, libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep])
dependencies : [libelf, libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep,
libffi_dep, libiconv, libz_dep])
gio_querymodules = executable('gio-querymodules', 'gio-querymodules.c', 'giomodule-priv.c',
install : true,
c_args : gio_c_args,
# intl.lib is not compatible with SAFESEH
link_args : noseh_link_args,
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep])
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep,
libffi_dep, libiconv])
glib_compile_schemas = executable('glib-compile-schemas',
[gconstructor_as_data_h, 'gvdb/gvdb-builder.c', 'glib-compile-schemas.c'],
install : true,
# intl.lib is not compatible with SAFESEH
link_args : noseh_link_args,
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep])
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep, libiconv])
glib_compile_resources = executable('glib-compile-resources',
[gconstructor_as_data_h, 'gvdb/gvdb-builder.c', 'glib-compile-resources.c'],
......@@ -909,14 +912,16 @@ glib_compile_resources = executable('glib-compile-resources',
c_args : gio_c_args,
# intl.lib is not compatible with SAFESEH
link_args : noseh_link_args,
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep])
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep,
libffi_dep, libiconv, libz_dep])
executable('gsettings', 'gsettings-tool.c',
install : true,
c_args : gio_c_args,
# intl.lib is not compatible with SAFESEH
link_args : noseh_link_args,
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep])
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep,
libffi_dep, libiconv, libz_dep])
install_data('gschema.dtd',
install_dir : join_paths(get_option('datadir'), 'glib-2.0/schemas'))
......@@ -928,7 +933,8 @@ executable('gdbus', 'gdbus-tool.c',
c_args : gio_c_args,
# intl.lib is not compatible with SAFESEH
link_args : noseh_link_args,
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep])
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep,
libffi_dep, libiconv, libz_dep])
if host_system != 'windows' and not glib_have_cocoa
executable('gapplication', 'gapplication-tool.c',
......@@ -936,7 +942,8 @@ if host_system != 'windows' and not glib_have_cocoa
c_args : gio_c_args,
# intl.lib is not compatible with SAFESEH
link_args : noseh_link_args,
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep])
dependencies : [libgio_dep, libgobject_dep, libgmodule_dep, libglib_dep,
libffi_dep, libiconv, libz_dep])
endif
if enable_systemtap
......
common_gio_tests_deps = [
libiconv,
libffi_dep,
libglib_dep,
libgmodule_dep,
libgobject_dep,
libgio_dep,
libz_dep,
]
subdir('gdbus-object-manager-example')
......
......@@ -293,7 +293,7 @@ else
gtester = executable('gtester', 'gtester.c',
install : true,
include_directories : configinc,
dependencies : [libglib_dep])
dependencies : [libglib_dep, libiconv])
endif
install_data('gtester-report', install_dir : get_option('bindir'))
......
......@@ -107,7 +107,7 @@ slow_tests = [
]
foreach test_name : glib_tests
deps = [libm, thread_dep, libglib_dep]
deps = [libm, thread_dep, libglib_dep, libiconv]
if test_name == 'regex'
deps += [pcre]
endif
......@@ -132,7 +132,7 @@ if cc.get_id() == 'gcc'
c_args_atomic += ['-Wstrict-aliasing=2']
endif
deps = [libm, thread_dep, libglib_dep]
deps = [libm, thread_dep, libglib_dep, libiconv]
exe = executable('atomic', 'atomic.c',
c_args : test_cargs + c_args_atomic,
......
......@@ -109,7 +109,7 @@ endforeach
executable('gobject-query', 'gobject-query.c',
install : true,
dependencies : [libglib_dep, libgobject_dep])
dependencies : [libglib_dep, libgobject_dep, libiconv, libffi_dep])
install_data('gobject_gdb.py', install_dir : join_paths(glib_pkgdatadir, 'gdb'))
gdb_conf = configuration_data()
......
......@@ -31,7 +31,7 @@ test_env = [
]
foreach test_name : gobject_tests
deps = [libm, thread_dep, libglib_dep, libgobject_dep]
deps = [libm, thread_dep, libglib_dep, libgobject_dep, libiconv, libffi_dep]
test_src = '@0@.c'.format(test_name)
# private is an existing or reserved target it seems
if test_name == 'private'
......
......@@ -52,7 +52,8 @@ foreach t : gobject_tests
# FIXME? $(GLIB_DEBUG_FLAGS)
exe = executable(test_name + '-gobject', test_src,
c_args : test_cargs + test_extra_cargs + ['-DGLIB_DISABLE_DEPRECATION_WARNINGS'],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep,
libiconv, libffi_dep],
install : false,
)
# FIXME? TESTS_ENVIRONMENT = LIBCHARSET_ALIAS_DIR=$(top_builddir)/glib/libcharset
......@@ -62,17 +63,20 @@ endforeach
# Don't install these ones, and keep them out of 'make check' because they take too long...
executable('performance', 'performance.c',
c_args : test_cargs + test_extra_cargs + ['-DGLIB_DISABLE_DEPRECATION_WARNINGS'],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep,
libffi_dep, libiconv],
install : false)
executable('performance-threaded', 'performance-threaded.c',
c_args : test_cargs + test_extra_cargs + ['-DGLIB_DISABLE_DEPRECATION_WARNINGS'],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep,
libffi_dep, libiconv],
install : false)
if host_system != 'windows' and host_system != 'minix'
executable('timeloop-closure', 'timeloop-closure.c',
c_args : test_cargs + test_extra_cargs + ['-DGLIB_DISABLE_DEPRECATION_WARNINGS'],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep,
libffi_dep, libiconv],
install : false)
endif
......@@ -21,7 +21,8 @@ foreach t : refcount_tests
# FIXME? $(GLIB_DEBUG_FLAGS)
exe = executable(test_name + '-test', test_src,
c_args : test_cargs + test_extra_cargs + ['-DGLIB_DISABLE_DEPRECATION_WARNINGS'],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep],
dependencies : [libm, thread_dep, libglib_dep, libgobject_dep,
libffi_dep, libiconv],
install : false,
)
# FIXME? TESTS_ENVIRONMENT = LIBCHARSET_ALIAS_DIR=$(top_builddir)/glib/libcharset
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment