builds libnl and inotify-tools
authorThierry Parmentelat <thierry.parmentelat@sophia.inria.fr>
Fri, 26 Sep 2008 17:22:00 +0000 (17:22 +0000)
committerThierry Parmentelat <thierry.parmentelat@sophia.inria.fr>
Fri, 26 Sep 2008 17:22:00 +0000 (17:22 +0000)
all uses of the 'kexcludes' fields, including in nodeconfig - now defined in build.common
reviewed packages list - dismantled fc4, fc6 and f7

12 files changed:
README-lstfiles.txt
build.common
config.planetlab/bootcd.pkgs
config.planetlab/bootstrapfs.pkgs
config.planetlab/devel.pkgs
config.planetlab/myplc.pkgs
config.planetlab/vserver.pkgs
getkexcludes.sh [new file with mode: 0755]
mirroring/mirror.sh
onelab.mk
planetlab.mk
vbuild-fedora-mirror.sh

index c730e84..0181eac 100644 (file)
@@ -3,10 +3,10 @@
 
 # to define packages on all fcdistros
 package: p1 p2 p3 p4
-# to add  packages for say fc6
-package+fc6: p5 p6
+# to add  packages for say f9
+package+f9: p5 p6
 # to exclude packages
-package-fc6: p2 p3
+package-f9: p2 p3
 
 # same for groups
 # NOTE: white spaces are not supported any more for group names
index 153a010..1b00ea8 100644 (file)
@@ -33,17 +33,14 @@ function pl_getRelease() {
     return 0
 }
 
-# vserver expects something like fc4 or f7
+# vserver expects something like f8 or centos5
 function pl_getReleaseName () {
     distro=$1; shift
     release=$1; shift
     case $distro in
        [Ff]edora*)
-           if [ "$release" -le 6 ] ; then
-               releasename=fc$release
-           else
-               releasename=f$release
-           fi ;;
+           releasename=f$release
+           ;;
        [Cc]entOS*)
            old_IFS="$IFS"
            IFS="."
@@ -61,6 +58,21 @@ function pl_getReleaseName () {
     return 0
 }
 
+function pl_getKexcludes () {
+    distroname=$1; shift
+    case $distroname in 
+       f*)
+           echo 'kernel* util-vserver* iptables iproute inotify-tools* libnl*'
+           ;;
+       centos*)
+           echo 'kernel* util-vserver* iptables iproute inotify-tools* libnl*'
+           ;;
+       *)
+           echo "pl_DISTRO_NAME=$pl_DISTRO_NAME not supported in getexcludes.sh"
+           ;;
+    esac
+}
+
 # figure out which redhat distro we are using (fedora, centos, redhat)
 pl_DISTRO=$(pl_getDistro)
 
@@ -70,12 +82,15 @@ pl_DISTRO_ARCH=$(uname -i 2>/dev/null|| echo unknownarch)
 # the release number (plain number)
 pl_DISTRO_RELEASE=$(pl_getRelease)
 
-# the release name - for vserver build - like fc4, f8 or centos4
+# the release name - for vserver build ...
 pl_DISTRO_NAME=$(pl_getReleaseName $pl_DISTRO $pl_DISTRO_RELEASE)
 
+# the packages to exclude
+pl_KEXCLUDES=$(pl_getKexcludes $pl_DISTRO_NAME)
+
 # get path to appropriate yumgroups.xml file
 # Thierry: quick & dirty improvement 
-# this file is updated by the toplevel build, from groups/<pldistro>.xml
+# this file is updated by the toplevel build, from the .pkgs files
 pl_DISTRO_YUMGROUPS="../../../RPMS/yumgroups.xml"
 
 function pl_process_fedora_options () {
@@ -186,13 +201,8 @@ function pl_root_mkfedora () {
     basearch=$pl_DISTRO_ARCH
 
 # Get options
-###    mirrors=""
-###    while getopts "l:r:a:vh" opt ; do
     while getopts "vh" opt ; do
        case $opt in
-###        l) mirrors="$mirrors $OPTARG" ;;
-###        r) releasever=$OPTARG ;;
-###        a) basearch=$OPTARG ;;
            v) verbose=1; set -x ;;
            h|*) mkfedora_usage ;;
        esac
@@ -211,12 +221,15 @@ function pl_root_mkfedora () {
     fcdistro=${pl_DISTRO_NAME}
     pkgs_packages=$(pl_parsePkgs package $fcdistro $pldistro $pkgsfile) 
     pkgs_groups=$(pl_parsePkgs group $fcdistro $pldistro $pkgsfile)
-    # packages to exclude - obsolete, was maybe useful when installing a group
+    # packages to exclude 
     pkgs_excludes=$(pl_parsePkgs exclude $fcdistro $pldistro $pkgsfile) 
+    # what can get trashed to save space
     pkgs_junk=$(pl_parsePkgs junk $fcdistro $pldistro $pkgsfile)
+    # but not this
     pkgs_precious=$(pl_parsePkgs precious $fcdistro $pldistro $pkgsfile)
-    # formerly related to mkfedora -k
-    pkgs_kexcludes=$(pl_parsePkgs kexclude $fcdistro $pldistro $pkgsfile)
+    # formerly related to mkfedora -k : packages to take from our own build 
+    # and thus need be excluded frem the stock repos
+    pkgs_kexcludes="$pl_KEXCLUDES"
     # get mirrors if not specified with -l
     if [ -z "$mirrors" ] ; then
        mirrorsfile=$(pl_locateDistroFile ../build/ $pldistro "$pldistro.mirrors")
index ff8b245..748ce5c 100644 (file)
@@ -1,9 +1,6 @@
 groupname: PlanetLabBootcd
 groupdesc: PlanetLab BootCD
-# This is the replacement for the former mkfedora -k. The following packages
-# will get excluded from the stock fedora repos, as we need to use ours
-kexclude: kernel* util-vserver* iptables iproute 
-# from prep.sh, was hardwired as packagelist
+# define packages - kecludes are defined in build.common
 package: filesystem
 package: udev
 package: dhclient
index 3ea001c..d4c6d27 100644 (file)
@@ -2,10 +2,7 @@
 # groupname: Bootstrapfs
 groupname: PlanetLab
 groupdesc: PlanetLab Node Root
-# This is the replacement for the former mkfedora -k. The following packages
-# will get excluded from the stock fedora repos, as we need to use ours
-kexclude: kernel* util-vserver* iptables iproute 
-#
+# define packages - kecludes are defined in build.common
 package: kernel
 package: udev
 package: basesystem
@@ -84,29 +81,18 @@ package: nfs-utils
 package: openvpn
 package: vconfig
 package: PyXML
+
 #
 # platform-dependent
 #
-package+fc4: sysklogd
-package+fc6: sysklogd
-package+f7: sysklogd
-package+f8: rsyslog
+package: rsyslog
+package-centos5: rsyslog
 package+centos5: sysklogd
 
-package+fc4: util-linux
-package+fc6: util-linux
-package+f7: util-linux
-package+f8: util-linux-ng
+package: util-linux-ng
+package-centos5: util-linux-ng
 package+centos5: util-linux
 
-# not found on other platforms
-package+fc4: netdump
-package+fc4: schedutils
-package+fc4: SysVinit
-package+fc4: portmap
-# 
-package+fc6: SysVinit
-package+fc6: portmap
 #
 # planetlab
 #
@@ -128,8 +114,6 @@ package: ipod
 package: vserver-@pldistro@-@fcdistro@-@arch@
 package: vserver-systemslices-@pldistro@-@fcdistro@-@arch@
 package: pl_mom
-package+f8: fprobe-ulog
+package: fprobe-ulog
 package: vsys
-package-fc4: vsys
-package-fc6: vsys
 package: monitor
index 4a07e56..bcc3ad1 100644 (file)
@@ -76,9 +76,9 @@ package: PyXML
 # for pypcilib
 package: pciutils-devel
 # for vsys
-package: ocaml ocaml-docs inotify-tools-devel 
-package-fc4: ocaml ocaml-docs inotify-tools-devel 
-package-fc6: ocaml ocaml-docs inotify-tools-devel 
-package-centos5: ocaml ocaml-docs inotify-tools-devel 
-# util-vserver-pl
-package: libnl libnl-devel
+package: ocaml ocaml-docs 
+## will be loaded from our build as needed 
+#package:inotify-tools-devel 
+## for util-vserver-pl
+## ditto
+#package: libnl libnl-devel
index 5beb732..db3f53d 100644 (file)
@@ -34,8 +34,6 @@ package:nmap
 package:python python-devel SOAPpy PyXML
 # add ons for plcapi
 package: python-pycurl python-psycopg2
-# but not on fc4 as we provide ours
-package-fc4: python-pycurl python-psycopg2
 # postgresql
 package:postgresql postgresql-server postgresql-python
 # apache
index 75fcb1b..2dabedc 100644 (file)
@@ -1,9 +1,6 @@
 groupname: PlanetLabSlice
 groupdesc: PlanetLab Slice Reference Image
-# This is the replacement for the former mkfedora -k. The following packages
-# will get excluded from the stock fedora repos, as we need to use ours
-kexclude: kernel* util-vserver* iptables iproute 
-# define packages
+# define packages - kecludes are defined in build.common
 package: bash
 package: coreutils
 package: iputils
diff --git a/getkexcludes.sh b/getkexcludes.sh
new file mode 100755 (executable)
index 0000000..8e001a3
--- /dev/null
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+COMMAND=$(basename $0)
+. $(dirname $0)/build.common
+
+function usage () {
+    echo "Usage: $COMMAND"
+    echo "outputs the list of packages to exclude from the stock repositories"
+    echo "this is set in build.common, and needs to fit the set of packages"
+    echo "that we override in the planetlab build"
+    exit 1
+}
+
+[[ -n "$@" ]] && usage
+
+echo "$pl_KEXCLUDES"
+
+
+
+       
+
index 58d9adb..467ddef 100755 (executable)
@@ -6,7 +6,7 @@ DIRNAME=$(dirname $0)
 
 default_url="http://localhost/mirror/"
 default_distro="f8"
-all_distros="fc4 fc6 f7 f8 f9 centos5"
+all_distros="f8 f9 centos5"
 
 function check_distro () {
     local distro=$1; shift
index f7c8e1b..75990a0 100644 (file)
--- a/onelab.mk
+++ b/onelab.mk
@@ -1,5 +1,5 @@
 #
-# OneLab standard components list
+# declare the packages to be built and their dependencies
 # initial version from Mark Huang
 # Mark Huang <mlhuang@cs.princeton.edu>
 # Copyright (C) 2003-2006 The Trustees of Princeton University
@@ -39,18 +39,6 @@ IN_BOOTSTRAPFS += $(KERNELS)
 # turns out myplc installs kernel-vserver
 IN_MYPLC += $(KERNELS)
 
-#
-# kexec-tools
-#
-ifeq "$(DISTRONAME)" "fc4"
-kexec-tools-MODULES := kexec-tools
-kexec-tools-SPEC := kexec-tools.spec
-kexec-tools-CVSROOT := :pserver:anon@cvs.planet-lab.org:/cvs
-kexec-tools-TAG := planetlab-4_1-rc2
-ALL += kexec-tools
-IN_BOOTCD += kexec-tools
-endif
-
 #
 # madwifi
 #
@@ -93,22 +81,32 @@ util-vserver-RPMFLAGS:= --without dietlibc
 ALL += util-vserver
 IN_BOOTSTRAPFS += util-vserver
 
+#
+# libnl - local import
+# the version available in centos 5.2 is too old
+# we need either 1.1 or at least 1.0.pre6
+#
+libnl-MODULES := libnl
+libnl-SPEC := libnl.spec
+ALL += libnl
+IN_BOOTSTRAPFS += libnl
+
 #
 # util-vserver-pl
 #
 util-vserver-pl-MODULES := util-vserver-pl
 util-vserver-pl-SPEC := util-vserver-pl.spec
-util-vserver-pl-DEPEND-DEVEL-RPMS := util-vserver-lib util-vserver-devel util-vserver-core
+util-vserver-pl-DEPEND-DEVEL-RPMS := util-vserver-lib util-vserver-devel util-vserver-core libnl-devel
 ALL += util-vserver-pl
 IN_BOOTSTRAPFS += util-vserver-pl
 
 #
 # NodeUpdate
 #
-NodeUpdate-MODULES := NodeUpdate
-NodeUpdate-SPEC := NodeUpdate.spec
-ALL += NodeUpdate
-IN_BOOTSTRAPFS += NodeUpdate
+nodeupdate-MODULES := NodeUpdate
+nodeupdate-SPEC := NodeUpdate.spec
+ALL += nodeupdate
+IN_BOOTSTRAPFS += nodeupdate
 
 #
 # ipod
@@ -121,18 +119,18 @@ IN_BOOTSTRAPFS += ipod
 #
 # NodeManager
 #
-NodeManager-MODULES := NodeManager
-NodeManager-SPEC := NodeManager.spec
-ALL += NodeManager
-IN_BOOTSTRAPFS += NodeManager
+nodemanager-MODULES := NodeManager
+nodemanager-SPEC := NodeManager.spec
+ALL += nodemanager
+IN_BOOTSTRAPFS += nodemanager
 
 #
 # pl_sshd
 #
-pl_sshd-MODULES := pl_sshd
-pl_sshd-SPEC := pl_sshd.spec
-ALL += pl_sshd
-IN_BOOTSTRAPFS += pl_sshd
+sshd-MODULES := pl_sshd
+sshd-SPEC := pl_sshd.spec
+ALL += sshd
+IN_BOOTSTRAPFS += sshd
 
 #
 # codemux: Port 80 demux
@@ -158,14 +156,13 @@ pf2slice-MODULES := pf2slice
 pf2slice-SPEC := pf2slice.spec
 ALL += pf2slice
 
-
 #
 # PlanetLab Mom: Cleans up your mess
 #
-pl_mom-MODULES := Mom
-pl_mom-SPEC := pl_mom.spec
-ALL += pl_mom
-IN_BOOTSTRAPFS += pl_mom
+mom-MODULES := Mom
+mom-SPEC := pl_mom.spec
+ALL += mom
+IN_BOOTSTRAPFS += mom
 
 #
 # iptables
@@ -187,26 +184,23 @@ IN_VSERVER += iproute
 IN_BOOTCD += iproute
 
 #
-# vsys
+# inotify-tools - local import
+# could not find this in cen
 #
-vsys_support=yes
-ifeq "$(DISTRONAME)" "fc4"
-vsys_support=
-endif
-ifeq "$(DISTRONAME)" "fc6"
-vsys_support=
-endif
-# cannot find the required packages (see devel.pkgs) on centos5
-ifeq "$(DISTRONAME)" "centos5"
-vsys_support=
-endif
+inotify-tools-MODULES := inotify-tools
+inotify-tools-SPEC := inotify-tools.spec
+inotify-tools-BUILD-FROM-SRPM := yes
+IN_BOOTSTRAPFS += inotify-tools
+ALL += inotify-tools
 
-ifeq "$(vsys_support)" "yes"
+#
+# vsys
+#
 vsys-MODULES := vsys
 vsys-SPEC := vsys.spec
+vsys-DEPEND-DEVEL-RPMS := inotify-tools-devel
 IN_BOOTSTRAPFS += vsys
 ALL += vsys
-endif
 
 #
 # dummynet_image
@@ -235,10 +229,10 @@ IN_MYPLC += PLCWWW
 #
 # monitor
 #
-Monitor-MODULES := Monitor
-Monitor-SPEC := Monitor.spec
-ALL += Monitor
-IN_BOOTSTRAPFS += Monitor
+monitor-MODULES := Monitor
+monitor-SPEC := Monitor.spec
+ALL += monitor
+IN_BOOTSTRAPFS += monitor
 
 #
 # monitor-server
@@ -250,7 +244,7 @@ ALL += monitor-server
 #
 # nodeconfig
 #
-nodeconfig-MODULES := nodeconfig
+nodeconfig-MODULES := nodeconfig build
 nodeconfig-SPEC := nodeconfig.spec
 ALL += nodeconfig
 IN_MYPLC += nodeconfig
index cfbf343..c84ec5c 100644 (file)
@@ -1,5 +1,5 @@
 #
-# PlanetLab standard components list
+# declare the packages to be built and their dependencies
 # initial version from Mark Huang
 # Mark Huang <mlhuang@cs.princeton.edu>
 # Copyright (C) 2003-2006 The Trustees of Princeton University
@@ -60,15 +60,15 @@ util-vserver-RPMFLAGS:= --without dietlibc
 ALL += util-vserver
 IN_BOOTSTRAPFS += util-vserver
 
-## #
-## # libnl - local import
-## # the version available in centos 5.2 is too old
-## # we need either 1.1 or at least 1.0.pre6
-## #
-## libnl-MODULES := libnl
-## libnl-SPEC := libnl.spec
-## ALL += libnl
-## IN_BOOTSTRAPFS += libnl
+#
+# libnl - local import
+# the version available in centos 5.2 is too old
+# we need either 1.1 or at least 1.0.pre6
+#
+libnl-MODULES := libnl
+libnl-SPEC := libnl.spec
+ALL += libnl
+IN_BOOTSTRAPFS += libnl
 
 #
 # util-vserver-pl
@@ -174,10 +174,10 @@ ALL += inotify-tools
 
 #
 # vsys
-# should now work on f{8,9} , and even centos 5.2
 #
 vsys-MODULES := vsys
 vsys-SPEC := vsys.spec
+vsys-DEPEND-DEVEL-RPMS := inotify-tools-devel
 IN_BOOTSTRAPFS += vsys
 ALL += vsys
 
@@ -215,7 +215,7 @@ ALL += monitor-server
 #
 # nodeconfig
 #
-nodeconfig-MODULES := nodeconfig
+nodeconfig-MODULES := nodeconfig build
 nodeconfig-SPEC := nodeconfig.spec
 ALL += nodeconfig
 IN_MYPLC += nodeconfig
@@ -242,7 +242,6 @@ IN_BOOTCD += pypcilib
 bootcd-MODULES := BootCD build
 bootcd-SPEC := bootcd.spec
 bootcd-RPMBUILD := sudo bash ./rpmbuild.sh
-# package has *some* dependencies, at least these ones
 bootcd-DEPEND-PACKAGES := $(IN_BOOTCD)
 bootcd-DEPEND-FILES := RPMS/yumgroups.xml
 bootcd-RPMDATE := yes
@@ -256,8 +255,6 @@ vserver-MODULES := VserverReference build
 vserver-SPEC := vserver-reference.spec
 # Package must be built as root
 vserver-RPMBUILD := sudo bash ./rpmbuild.sh
-# this list is useful for manual builds only, since nightly builds 
-# always redo all sequentially - try to keep updated
 vserver-DEPEND-PACKAGES := $(IN_VSERVER)
 vserver-DEPEND-FILES := RPMS/yumgroups.xml
 vserver-RPMDATE := yes
@@ -270,7 +267,6 @@ IN_BOOTSTRAPFS += vserver
 bootstrapfs-MODULES := BootstrapFS build
 bootstrapfs-SPEC := bootstrapfs.spec
 bootstrapfs-RPMBUILD := sudo bash ./rpmbuild.sh
-# package requires all regular packages
 bootstrapfs-DEPEND-PACKAGES := $(IN_BOOTSTRAPFS)
 bootstrapfs-DEPEND-FILES := RPMS/yumgroups.xml
 bootstrapfs-RPMDATE := yes
index 9f7e8b5..a178ff4 100755 (executable)
@@ -163,7 +163,7 @@ function usage () {
     echo " -s : uses standard (US) mirrors $us_fedora_url $us_centos_url"
     echo " -e : uses European mirrors $eu_fedora_url $eu_centos_url"
     echo " -j : uses Japanese mirrors $jp_fedora_url $jp_centos_url"
-    echo " -f distroname - use vserver convention, e.g. fc6 and f7"
+    echo " -f distroname - use vserver convention, e.g. f8 or centos5"
     echo " -F : for distroname in $all_distronames"
     echo " -a arch - use yum convention"
     echo " -A : for arch in $all_archs"