diff --git a/ChangeLog b/ChangeLog index b8609f84..c1ab073c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2024-08-17 Araki Ken + + * configure.in, tool/mlconfig/Makefile.in: Set X_LIBS_FOR_MLCONFIG + if the version of gtk+ is 2.x to build gtkxlfdsel.c. + 2024-08-16 Araki Ken * Merge https://github.com/arakiken/mlterm/issues/107 diff --git a/configure b/configure index 7f2aaa6b..b6ac7d6c 100755 --- a/configure +++ b/configure @@ -704,6 +704,7 @@ LIBPNG_CFLAGS PERL GTK_LIBS_FOR_MLCONFIG GTK_CFLAGS_FOR_MLCONFIG +X_LIBS_FOR_MLCONFIG MKINSTALLDIRS POSUB POFILES @@ -21622,11 +21623,16 @@ $as_echo "$LINGUAS" >&6; } GTK_CFLAGS_FOR_MLCONFIG=$GTK4_CFLAGS GTK_LIBS_FOR_MLCONFIG=$GTK4_LIBS else + if test "$gtk_version" = "2.0"; then + # for gtkxlfdsel.c + X_LIBS_FOR_MLCONFIG=$X_LIBS + fi GTK_CFLAGS_FOR_MLCONFIG=$GTK_CFLAGS GTK_LIBS_FOR_MLCONFIG=$GTK_LIBS fi + else echo "" echo "** WARNING **" diff --git a/configure.in b/configure.in index 086876cc..454fb7cb 100644 --- a/configure.in +++ b/configure.in @@ -1132,9 +1132,14 @@ mlconfig) GTK_CFLAGS_FOR_MLCONFIG=$GTK4_CFLAGS GTK_LIBS_FOR_MLCONFIG=$GTK4_LIBS else + if test "$gtk_version" = "2.0"; then + # for gtkxlfdsel.c + X_LIBS_FOR_MLCONFIG=$X_LIBS + fi GTK_CFLAGS_FOR_MLCONFIG=$GTK_CFLAGS GTK_LIBS_FOR_MLCONFIG=$GTK_LIBS fi + AC_SUBST(X_LIBS_FOR_MLCONFIG) AC_SUBST(GTK_CFLAGS_FOR_MLCONFIG) AC_SUBST(GTK_LIBS_FOR_MLCONFIG) else diff --git a/tool/mlconfig/Makefile.in b/tool/mlconfig/Makefile.in index 95a01ec9..7e49dbc8 100644 --- a/tool/mlconfig/Makefile.in +++ b/tool/mlconfig/Makefile.in @@ -33,11 +33,11 @@ CFLAGS = $(CFLAGS_LOCAL) @GTK_CFLAGS_FOR_MLCONFIG@ @IMAGELIB_CFLAGS@ @DEB_CFLAGS LIBS1 = $(LIBS_LOCAL) @INTL_LIBS@ @DL_SELF@ @DL_LIBS_IM@ @GTK_LIBS_FOR_MLCONFIG@ # -lX11 is for http://fedoraproject.org/wiki/Features/ChangeInImplicitDSOLinking -LIBS2_xlib = $(LPOBL) @X_LIBS@ +LIBS2_xlib = $(LPOBL) @X_LIBS_FOR_MLCONFIG@ -LIBS2_wayland = $(LPOBL) +LIBS2_wayland = $(LPOBL) @X_LIBS_FOR_MLCONFIG@ -LIBS2_sdl2 = $(LPOBL) +LIBS2_sdl2 = $(LPOBL) @X_LIBS_FOR_MLCONFIG@ # mlconfig is statically linked with libpobl. # Then it works if installed libpobl.dll is compiled with USE_WIN32API or not.