Make dhcpcd-online an optional component for split packages.
authorRoy Marples <roy@marples.name>
Wed, 17 Sep 2014 09:24:11 +0000 (09:24 +0000)
committerRoy Marples <roy@marples.name>
Wed, 17 Sep 2014 09:24:11 +0000 (09:24 +0000)
configure
src/Makefile

index 257f112d7e75c0d8b598499ab3da465999d091ef..1e0220a9cd787e40974dee0a5c64172bf7ac0db9 100755 (executable)
--- a/configure
+++ b/configure
@@ -4,9 +4,12 @@
 # Ensure that we do not inherit these from env
 DEBUG=
 LIBDHCPCD=no
+WITH_DHCPCD_ONLINE=yes
 WITH_GTK=
+WITH_QT=
 NOTIFY=yes
 INCLUDEDIR=
+UI=
 
 for x; do
        opt=${x%%=*}
@@ -34,6 +37,8 @@ for x; do
        --includedir) eval INCLUDEDIR="$INCLUDEDIR${INCLUDEDIR:+ }$var";;
        --datadir|--infodir) ;; # ignore autotools
        --disable-maintainer-mode|--disable-dependency-tracking) ;;
+       --with-dhcpcd-online) WITH_DHCPCD_ONLINE=${var:-yes};;
+       --without-dhcpcd-online) WITH_DHCPCD_ONLINE=no;;
        --with-gtk|--with-gtk+) WITH_GTK=${var:-yes};;
        --without-gtk|--without-gtk+) WITH_GTK=no;;
        --with-qt) WITH_QT=${var:-yes};;
@@ -318,7 +323,6 @@ echo "LIB_DHCPCD=   $x" >>$CONFIG_MK
 # what we actually need.
 echo "LDADD+=          -Wl,--as-needed" >>$CONFIG_MK
 
-UI=
 if [ "$WITH_GTK" = yes -o -z "$WITH_GTK" ]; then
        if pkg-config --cflags gtk+-2.0 >/dev/null 2>&1; then
                WITH_GTK="gtk+-2.0"
@@ -368,6 +372,10 @@ fi
 if [ -n "$UI" ]; then
        echo "MKICONS=  icons" >>$CONFIG_MK
 fi
+
+if [ -n "$WITH_DHCPCD_ONLINE" -a "$WITH_DHCPCD_ONLINE" != no ]; then
+       UI="dhcpcd-online${UI:+ }$UI"
+fi
 echo "UI=              $UI" >>$CONFIG_MK
 
 echo
index c51eac1d590ea86e4d7fd9c668470ed01fc20120..cf96e6292ee2238685eb469e5a226a7d49f035ba 100644 (file)
@@ -1,6 +1,6 @@
 TOPDIR=                ..
 include ${TOPDIR}/iconfig.mk
 
-SUBDIR=                libdhcpcd dhcpcd-online ${UI}
+SUBDIR=                libdhcpcd ${UI}
 
 include ${MKDIR}/subdir.mk