diff options
Diffstat (limited to 'media-radio/unixcw/files/unixcw-2.3-config.patch')
-rw-r--r-- | media-radio/unixcw/files/unixcw-2.3-config.patch | 88 |
1 files changed, 74 insertions, 14 deletions
diff --git a/media-radio/unixcw/files/unixcw-2.3-config.patch b/media-radio/unixcw/files/unixcw-2.3-config.patch index acd447bfe..23f6a1464 100644 --- a/media-radio/unixcw/files/unixcw-2.3-config.patch +++ b/media-radio/unixcw/files/unixcw-2.3-config.patch @@ -1,5 +1,5 @@ ---- configure.ac.orig 2006-07-13 07:31:21.000000000 +0200 -+++ configure.ac 2008-06-08 14:30:41.000000000 +0200 +--- configure.ac.orig 2010-01-27 20:00:28.000000000 +0100 ++++ configure.ac 2010-01-27 20:05:41.000000000 +0100 @@ -46,8 +46,24 @@ AC_SUBST(GZIP) AC_SUBST(LDCONFIG) @@ -11,9 +11,9 @@ + [enable_ncurses="no"]) +AC_MSG_RESULT($enable_ncurses) + -+AC_MSG_CHECKING(--enable-qt3 argument) -+AC_ARG_ENABLE(qt3, -+ [ --enable-qt3 Include QT based Morse code Tutor], ++AC_MSG_CHECKING(--enable-qt4 argument) ++AC_ARG_ENABLE(qt4, ++ [ --enable-qt4 Include QT based Morse code Tutor], + [enable_qt=$enableval], + [enable_qt="no"]) +AC_MSG_RESULT($enable_qt) @@ -25,7 +25,7 @@ # Checks for header files, and refuse to go on if no KIOCSOUND is available. AC_HEADER_STDC -@@ -92,13 +108,17 @@ +@@ -92,49 +108,40 @@ # Decide on which subdirectories to build; substitute into SUBDIRS. Build # cwcp if curses is available, and xcwcp if Qt is available. SUBDIRS="cwlib cwutils cw cwgen" @@ -39,16 +39,76 @@ fi +fi -+if test "$enable_qt3" = 'yes'; then - # Look for $QTDIR. If found, then look for moc, either on $PATH, or - # in $QTDIR/bin. - MOC_EARLIEST=3 -@@ -135,6 +155,8 @@ - AC_MSG_WARN([Cannot find libqt - unable to build xcwcp]) - AC_MSG_WARN([Hint: try setting a value for the QTDIR variable]) +-# Look for $QTDIR. If found, then look for moc, either on $PATH, or +-# in $QTDIR/bin. +-MOC_EARLIEST=3 +-if test -n "$QTDIR" ; then +- AC_PATH_PROG(QTMOC, moc, , $QTDIR/bin:$PATH) +- if test -n "$QTMOC" ; then +- MOC_VERSION="`$QTMOC -v 2>&1 | sed -e 's;.*(Qt ;;' -e 's;).*;;'`" +- if test -n "$MOC_VERSION" ; then +- MOC_MAJOR="`echo $MOC_VERSION | sed -e 's;\..*;;'`" +- expr "$MOC_MAJOR" + 0 >/dev/null 2>/dev/null +- status=$? +- if test -n "$MOC_MAJOR" -a $status -eq 0 ; then +- if test "$MOC_MAJOR" -ge $MOC_EARLIEST ; then +- SUBDIRS="$SUBDIRS xcwcp" +- AC_SUBST(QTDIR) +- AC_SUBST(QTMOC) +- else +- AC_MSG_WARN([Found 'moc' $MOC_VERSION - unable to build xcwcp]) +- AC_MSG_WARN([Hint: xcwcp requires 'moc' version >= $MOC_EARLIEST]) +- fi +- else +- AC_MSG_WARN([Cannot find 'moc' version - unable to build xcwcp]) +- AC_MSG_WARN([Hint: ensure 'moc' is in QTDIR/bin on your PATH]) +- fi +- else +- AC_MSG_WARN([Cannot find 'moc' version - unable to build xcwcp]) +- AC_MSG_WARN([Hint: ensure 'moc' is in QTDIR/bin on your PATH]) +- fi +- else +- AC_MSG_WARN([Cannot find 'moc' - unable to build xcwcp]) +- AC_MSG_WARN([Hint: ensure 'moc' is in QTDIR/bin on your PATH]) +- fi ++if test "$enable_qt4" = 'yes'; then ++ dnl Look for Qt4 libs ++ PKG_CHECK_MODULES([QT4], ["QtCore QtGui Qt3Support"], [ ++ AC_SUBST(QT4_CFLAGS) ++ AC_SUBST(QT4_LIBS) ++ ], [ ++ AC_MSG_ERROR([Qt4 libs not found]) ++ ]) ++ dnl Look for moc, either on $PATH or in $QTDIR/bin ++ AC_PATH_PROG(QTMOC, moc, , $QTDIR/bin:$PATH) ++ if test -n "$QTMOC" ; then ++ dnl if libs and moc found ++ SUBDIRS="$SUBDIRS xcwcp" ++ AC_DEFINE([WANT_QT4], 1, [Want Qt4]) ++ echo "enabling Qt4 support" ++ else ++ AC_MSG_ERROR([Cannot find 'moc']) ++ AC_DEFINE([WANT_QT4], 0, [No Qt4]) ++ fi + else +- AC_MSG_WARN([Cannot find libqt - unable to build xcwcp]) +- AC_MSG_WARN([Hint: try setting a value for the QTDIR variable]) ++ AC_DEFINE([WANT_QT4], 0, [No Qt4]) ++ echo "disabling Qt4 support" fi -+fi + AC_SUBST(SUBDIRS) # Add -Wall, -W, -pedantic, and other paranoia to gcc command flags, and -Wall +--- Makefile.inc.in.orig 2010-01-27 20:11:31.000000000 +0100 ++++ Makefile.inc.in 2010-01-27 20:10:28.000000000 +0100 +@@ -37,7 +37,8 @@ + AC_LD_LINKS_SO = @LD_LINKS_SO@ + AC_LD = @LD@ + AC_LN_S = @LN_S@ +- ++AC_QT4_LIBS = @QT4_LIBS@ ++AC_QT4_CFLAGS = @QT4_CFLAGS@ + # Portability values. + INSTALL = @INSTALL@ + INSTALL_PROGRAM = @INSTALL_PROGRAM@ |