Skip to content

Commit

Permalink
tools: Fix to add -ldl LDADD
Browse files Browse the repository at this point in the history
-ldl option is needed for dlclose() in Ubuntu.

Also move the docs build order to the last.

Also unset G_MESSAGES_DEBUG for gsettings in xkb-latin-layouts.
gsettings cannot get the key value when G_MESSAGES_DEBUG is enabled.
  • Loading branch information
fujiwarat committed Jul 20, 2022
1 parent 92771d0 commit fee26c6
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 15 deletions.
2 changes: 1 addition & 1 deletion Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,13 @@ SUBDIRS = \
data \
m4 \
po \
docs \
$(ENGINE_DIR) \
$(UI_DIR) \
tools \
$(DAEMON_DIR) \
$(PYTHON_LIB_DIRS) \
$(SETUP_DIR) \
docs \
$(NULL)

ACLOCAL_AMFLAGS = -I m4
Expand Down
7 changes: 7 additions & 0 deletions src/tests/xkb-latin-layouts
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,16 @@ finit()

test_xkb_keymaps()
{
# G_MESSAGES_DEBUG=all or G_MESSAGES_DEBUG=GLib-GIO-DEBUG would append
# debug messages to gsettings output and could not get the result correctly.
backup_G_MESSAGES_DEBUG="$G_MESSAGES_DEBUG"
unset G_MESSAGES_DEBUG
# Loop over top level schemas since "gsettings list-recursively" only
# looks for direct children.
xkb_latin_layouts=`gsettings get org.freedesktop.ibus.general xkb-latin-layouts`
if [ x"$backup_G_MESSAGES_DEBUG" != x ] ; then
export G_MESSAGES_DEBUG=$backup_G_MESSAGES_DEBUG
fi
while read keymap ; do
eval keymap="$keymap"
HAS_VARIANT=$($ECHO "$keymap" | grep '(' 2> /dev/null) ||:
Expand Down
29 changes: 15 additions & 14 deletions tools/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -39,22 +39,22 @@ VAPIGEN_VAPIS =

# force include config.h before gi18n.h.
AM_CPPFLAGS = \
-I$(top_srcdir)/src \
-I$(top_builddir)/src \
-include $(CONFIG_HEADER) \
$(NULL)
-I$(top_srcdir)/src \
-I$(top_builddir)/src \
-include $(CONFIG_HEADER) \
$(NULL)

AM_CFLAGS = \
@GLIB2_CFLAGS@ \
@GIO2_CFLAGS@ \
@GTHREAD2_CFLAGS@ \
-DG_LOG_DOMAIN=\"IBUS\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
-DIBUS_DISABLE_DEPRECATED \
-Wno-unused-variable \
-Wno-unused-but-set-variable \
-Wno-unused-function \
$(NULL)
@GLIB2_CFLAGS@ \
@GIO2_CFLAGS@ \
@GTHREAD2_CFLAGS@ \
-DG_LOG_DOMAIN=\"IBUS\" \
-DLIBEXECDIR=\"$(libexecdir)\" \
-DIBUS_DISABLE_DEPRECATED \
-Wno-unused-variable \
-Wno-unused-but-set-variable \
-Wno-unused-function \
$(NULL)

AM_LDADD = \
@GOBJECT2_LIBS@ \
Expand All @@ -63,6 +63,7 @@ AM_LDADD = \
@GTHREAD2_LIBS@ \
$(libibus) \
$(libibusimmodule) \
-ldl \
$(NULL)

AM_VALAFLAGS = \
Expand Down

0 comments on commit fee26c6

Please sign in to comment.