summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilipp Rösner <rndxelement@protonmail.com>2022-05-09 22:32:40 +0200
committerSam James <sam@gentoo.org>2022-05-13 20:12:42 +0000
commitff966cb209c335d24b84891d174c2f0dcaa5e863 (patch)
tree782904475e29a0e27f9f90c96059dceecfb491b1 /games-puzzle
parentmedia-gfx/hydrus: Drop 478, add 484 (diff)
downloadgentoo-ff966cb209c335d24b84891d174c2f0dcaa5e863.tar.gz
gentoo-ff966cb209c335d24b84891d174c2f0dcaa5e863.tar.bz2
gentoo-ff966cb209c335d24b84891d174c2f0dcaa5e863.zip
games-puzzle/nudoku: fix pkgconf
On some systems the Autotools could not find the path to pkgconf in configure.ac due to a missing call to PKG_PROG_PKG_CONFIG. Closes: https://bugs.gentoo.org/764497 Signed-off-by: Philipp Rösner <rndxelement@protonmail.com> Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'games-puzzle')
-rw-r--r--games-puzzle/nudoku/files/nudoku-2.1.0-ncurses-link.patch42
1 files changed, 23 insertions, 19 deletions
diff --git a/games-puzzle/nudoku/files/nudoku-2.1.0-ncurses-link.patch b/games-puzzle/nudoku/files/nudoku-2.1.0-ncurses-link.patch
index 396dbccddccf..0a4b2a13a0c4 100644
--- a/games-puzzle/nudoku/files/nudoku-2.1.0-ncurses-link.patch
+++ b/games-puzzle/nudoku/files/nudoku-2.1.0-ncurses-link.patch
@@ -2,36 +2,40 @@ Ensure we link against the correct ncurses libraries.
https://bugs.gentoo.org/764470
--- a/src/Makefile.am
+++ b/src/Makefile.am
-@@ -1,11 +1,7 @@
- #AM_CFLAGS = --pedantic -Wall
+@@ -2,9 +2,9 @@
#-DDEBUG
--if HAVE_WIDE_NCURSES
+ if HAVE_WIDE_NCURSES
-nudoku_LDADD = -lncursesw
--else
++nudoku_LDADD = ${ncursesw_LIBS}
+ else
-nudoku_LDADD = -lncurses
--endif
+nudoku_LDADD = ${ncurses_LIBS}
+ endif
bin_PROGRAMS = nudoku
nudoku_SOURCES = main.c sudoku.c sudoku.h
-
+
--- a/configure.ac
+++ b/configure.ac
-@@ -34,15 +34,7 @@ the cairo development libraries, or compile without support (--disable-cairo)
+@@ -6,6 +6,9 @@ AC_INIT([nudoku], [2.1.0], [jubalh@iodoru.org])
+ AC_CONFIG_SRCDIR([src/main.c])
+ AM_INIT_AUTOMAKE([foreign])
++# Check for pkg-config
++PKG_PROG_PKG_CONFIG()
++
+ # Checks for programs.
+ AC_PROG_CC
+ # Use C99.
+@@ -35,9 +38,9 @@ the cairo development libraries, or compile without support (--disable-cairo)
fi
--have_wide_ncurses=no
+ have_wide_ncurses=no
-AC_CHECK_LIB(ncursesw, initscr, [have_wide_ncurses=yes])
--if test $have_wide_ncurses = no; then
++PKG_CHECK_MODULES([ncursesw], [ncursesw], [have_wide_ncurses=yes], [])
+ if test $have_wide_ncurses = no; then
- AC_CHECK_LIB(ncurses, initscr, [], [
-- echo "nudoku requires ncurses"
-- exit 1
-- ])
--fi
--AM_CONDITIONAL([HAVE_WIDE_NCURSES], [test $have_wide_ncurses = yes])
-+PKG_CHECK_MODULES([ncurses], [ncurses])
-
- # Checks for header files.
- AC_CHECK_HEADERS([stdlib.h string.h unistd.h])
-
++ PKG_CHECK_MODULES([ncurses], [ncurses], [], [
+ echo "nudoku requires ncurses"
+ exit 1
+ ])