From 144f1344adf60815c8c57e93b5ed0acf98bbc40f Mon Sep 17 00:00:00 2001 From: Daniel Joseph Barnhart Clark Date: Thu, 24 Aug 2006 03:21:17 +0000 Subject: EncapPackages: A bunch of changes, including but not limited to: * Cleaner directory structure * Numerous Makefile improvements * Makefile no longer tied to specific versions of encap packages (except in the case of python-apt, which is distro-specific) * Automatic dependancy generation from encap package files * bcfg2-site pretty much done git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@2103 ce84e21b-d406-0410-9b95-82705330c041 --- encap/ChangeLog | 54 +++ encap/HOWTO | 52 --- encap/INSTALL | 0 encap/Makefile | 116 ------ encap/README | 58 ++- encap/TODO | 27 +- encap/VERSION | 2 +- encap/src/Makefile | 19 + encap/src/bcfg2-site/Makefile | 26 +- .../bcfg2-site/bcfg2-site-RENAME/encapinfo.tmpl | 2 + .../etc/default/bcfg2-client/.SENTINEL_SITE | 0 .../etc/default/bcfg2-server/.SENTINEL_SITE | 0 .../src/bcfg2-site/bcfg2-site-RENAME/mkinstalldirs | 32 ++ encap/src/bcfg2-site/bcfg2-site-RENAME/postinstall | 81 ++++ encap/src/bcfg2-site/bcfg2-site-RENAME/preinstall | 0 encap/src/bcfg2-site/site-settings.conf | 46 --- encap/src/bcfg2-site/site-settings.conf-example | 46 +++ encap/src/encap-profiles/Makefile | 164 ++++++++ encap/src/encap-profiles/bcfg2-0.8.2.ep | 444 -------------------- encap/src/encap-profiles/bcfg2-0.8.3pre1.ep | 458 +++++++++++++++++++++ encap/src/encap-profiles/bcfg2-cheetah-2.0rc7.ep | 4 + .../encap-profiles/bcfg2-cheetah-doc-0.9.16a1.ep | 3 + encap/src/encap-profiles/bcfg2-gamin-0.1.7.ep | 10 +- encap/src/encap-profiles/bcfg2-gettext-0.14.5.ep | 11 +- encap/src/encap-profiles/bcfg2-glib-2.8.6.ep | 16 +- encap/src/encap-profiles/bcfg2-libiconv-1.9.2.ep | 10 +- encap/src/encap-profiles/bcfg2-libxml2-2.6.26.ep | 16 +- encap/src/encap-profiles/bcfg2-libxslt-1.1.17.ep | 15 +- encap/src/encap-profiles/bcfg2-lxml-1.0.1.ep | 15 +- encap/src/encap-profiles/bcfg2-openssl-0.9.8b.ep | 15 +- encap/src/encap-profiles/bcfg2-pkg-config-0.20.ep | 9 +- encap/src/encap-profiles/bcfg2-pyopenssl-0.6.ep | 13 +- encap/src/encap-profiles/bcfg2-pyrex-0.9.4.1.ep | 10 +- encap/src/encap-profiles/bcfg2-python-2.4.3.ep | 14 +- .../src/encap-profiles/bcfg2-python-apt-0.5.10.ep | 8 +- .../bcfg2-python-apt-0.6.16.2ubuntu8.ep | 10 +- .../src/encap-profiles/bcfg2-python-apt-0.6.19.ep | 8 +- encap/src/encap-profiles/bcfg2-zlib-1.2.3.ep | 10 +- encap/src/encap-profiles/daemontools-0.76.ep | 13 +- .../src/encap-profiles/daemontools-doc-20060731.ep | 7 +- encap/src/encap-profiles/ep2target | 40 ++ encap/src/encap-profiles/m4-1.4.4.sh | 4 +- encap/src/encap-profiles/makeself-2.1.4.ep | 2 + encap/src/encap-profiles/ostiary-3.4.ep | 24 +- encap/src/encap-profiles/ostiary-doc-20060801.ep | 7 +- encap/src/encap-profiles/patch-2.5.9.ep | 7 +- 46 files changed, 1156 insertions(+), 772 deletions(-) create mode 100644 encap/ChangeLog create mode 100644 encap/INSTALL delete mode 100644 encap/Makefile create mode 100644 encap/src/Makefile delete mode 100644 encap/src/bcfg2-site/bcfg2-site-RENAME/etc/default/bcfg2-client/.SENTINEL_SITE delete mode 100644 encap/src/bcfg2-site/bcfg2-site-RENAME/etc/default/bcfg2-server/.SENTINEL_SITE create mode 100755 encap/src/bcfg2-site/bcfg2-site-RENAME/mkinstalldirs delete mode 100755 encap/src/bcfg2-site/bcfg2-site-RENAME/preinstall delete mode 100644 encap/src/bcfg2-site/site-settings.conf create mode 100644 encap/src/bcfg2-site/site-settings.conf-example create mode 100644 encap/src/encap-profiles/Makefile delete mode 100644 encap/src/encap-profiles/bcfg2-0.8.2.ep create mode 100644 encap/src/encap-profiles/bcfg2-0.8.3pre1.ep create mode 100755 encap/src/encap-profiles/ep2target (limited to 'encap') diff --git a/encap/ChangeLog b/encap/ChangeLog new file mode 100644 index 000000000..b49550313 --- /dev/null +++ b/encap/ChangeLog @@ -0,0 +1,54 @@ +== Release Notes == + 0.1:: + * Initial Released Version + * Work needs to be done to minimize size of distribution. In 0.1 + libraries and binaries are not stripped, and there is a lot of + pruning that can be done of individual packages. + + 0.2:: + * Updated bcfg2 to 0.8.2pre7 + * Updated README to point to mcs.anl.gov resources + + 0.3:: + * Updated bcfg2 to 0.8.2pre10 + + 0.4:: + * Versions before this version won't work without manually fixing paths + * Added patches so paths actually exist, specifically: + * bcfg2.conf default location is /usr/local/etc + * epkg/encap paths changed to encap default /usr/local paths + * schema prefix patch (changeset 1953) applied + * default schema prefix changed to /usr/local/lib/bcfg2 + * Added mirror of all packages downloaded by the profiles at + http://www.pobox.com/users/dclark/mirror and made mirror default for + those downloads + * Set up automatic hourly mirror of bcfg2 ftp site *.tar.gz files + * Mirror of other packages is manual (but deps shouldn't change often) + + 0.5:: + * Removed external download of patches as that was not working consistently; + replaced with patches inline the bcfg2 encap profile (.ep file) + * Added GNU patch dependency, both for bcfg2 patches and call from Cfg.py + * Fixed bcfg-repo-validate so it can find xmllint (as b2-xmllint) + + 0.6:: + * Updated bcfg2 to 0.8.2 (released version) + * Removed r1953 patch from bcfg2 profile, since that is included in 0.8.2 + * Added alpha version warning + + 0.7:: + * Added Solaris support + + 0.8:: + * Added python code to fix paths; removed inline patch & GNU patch dependency + * Path change happens as part of install, logged to postinstall.log + * Changed prefix from b2 to b2- to disambiguate from system commands + * Fixes to make man pages easier to access + * Install tools as b2-example-tools-* + * Added some auxiliary tools under tools/ directory + * daemontools - cross-platform alternative to init scripts/cron + * ostiary - simple/secure daemon for kicking off a local script + * epkg Makefile - to build epkg when prebuilt binaries aren't available + + 0.9:: + * Major directory structure changes \ No newline at end of file diff --git a/encap/HOWTO b/encap/HOWTO index 488639c7f..4dcc12d24 100644 --- a/encap/HOWTO +++ b/encap/HOWTO @@ -121,57 +121,5 @@ machine. Note that the doc for the encap profile format is in "man 5 encap_profile". -== Release Notes == - 0.1:: - * Initial Released Version - * Work needs to be done to minimize size of distribution. In 0.1 - libraries and binaries are not stripped, and there is a lot of - pruning that can be done of individual packages. - - 0.2:: - * Updated bcfg2 to 0.8.2pre7 - * Updated README to point to mcs.anl.gov resources - - 0.3:: - * Updated bcfg2 to 0.8.2pre10 - - 0.4:: - * Versions before this version won't work without manually fixing paths - * Added patches so paths actually exist, specifically: - * bcfg2.conf default location is /usr/local/etc - * epkg/encap paths changed to encap default /usr/local paths - * schema prefix patch (changeset 1953) applied - * default schema prefix changed to /usr/local/lib/bcfg2 - * Added mirror of all packages downloaded by the profiles at - http://www.pobox.com/users/dclark/mirror and made mirror default for - those downloads - * Set up automatic hourly mirror of bcfg2 ftp site *.tar.gz files - * Mirror of other packages is manual (but deps shouldn't change often) - - 0.5:: - * Removed external download of patches as that was not working consistently; - replaced with patches inline the bcfg2 encap profile (.ep file) - * Added GNU patch dependency, both for bcfg2 patches and call from Cfg.py - * Fixed bcfg-repo-validate so it can find xmllint (as b2-xmllint) - - 0.6:: - * Updated bcfg2 to 0.8.2 (released version) - * Removed r1953 patch from bcfg2 profile, since that is included in 0.8.2 - * Added alpha version warning - - 0.7:: - * Added Solaris support - - 0.8:: - * Added python code to fix paths; removed inline patch & GNU patch dependency - * Path change happens as part of install, logged to postinstall.log - * Changed prefix from b2 to b2- to disambiguate from system commands - * Fixes to make man pages easier to access - * Install tools as b2-example-tools-* - * Added some auxiliary tools under tools/ directory - * daemontools - cross-platform alternative to init scripts/cron - * ostiary - simple/secure daemon for kicking off a local script - * epkg Makefile - to build epkg when prebuilt binaries aren't available - == Documentation Version == $Id$ diff --git a/encap/INSTALL b/encap/INSTALL new file mode 100644 index 000000000..e69de29bb diff --git a/encap/Makefile b/encap/Makefile deleted file mode 100644 index 45de670d0..000000000 --- a/encap/Makefile +++ /dev/null @@ -1,116 +0,0 @@ -# $Id$ - -.PHONY : all install clean uninstall encaps rename bcfg2only -.SUFFIXES : -.SUFFIXES : .ep .sh .installed .packaged - -BASEDIR = /usr/local -ENCAPDIR = ${BASEDIR}/encap -export ENCAPDIR -EPKG = ${BASEDIR}/bin/epkg -export EPKG -MKENCAP = ${BASEDIR}/bin/mkencap -export MKENCAP - -M4 = m4-1.4.4 -ZLIB = bcfg2-zlib-1.2.3 -LIBICONV = bcfg2-libiconv-1.9.2 -GETTEXT = bcfg2-gettext-0.14.5 -PKG-CONFIG = bcfg2-pkg-config-0.20 -OPENSSL = bcfg2-openssl-0.9.8b -LIBSTDCXX = bcfg2-libstdc++-0.1 -LIBGCC = bcfg2-libgcc-0.1 -PYTHON = bcfg2-python-2.4.3 -PYREX = bcfg2-pyrex-0.9.4.1 -PYOPENSSL = bcfg2-pyopenssl-0.6 -LIBXML2 = bcfg2-libxml2-2.6.26 -LIBXSLT = bcfg2-libxslt-1.1.17 -LXML = bcfg2-lxml-1.0.1 -BCFG2 = bcfg2-0.8.2 - -.ep.installed : # Clean, compile and install an encap package - @printf "***** START .ep.installed for |$*| ***** \n" - ( ${EPKG} -q -r ${ENCAPDIR}/$* || true ) - ( rm -rf ${ENCAPDIR}/$* || true ) - ( ${MKENCAP} -m /usr/local/bin/m4 -b -DUP $*.ep || true ) > $*.log 2>&1 - ( ${MKENCAP} -m /usr/local/bin/m4 -b -T $*.ep || true ) >> $*.log 2>&1 - ( ${MKENCAP} -m /usr/local/bin/m4 -b -CBI $*.ep ) >> $*.log 2>&1 - ${EPKG} -q -i ${ENCAPDIR}/$* - test -h ${BASEDIR}/var/encap/$* - touch $*.installed - @printf "***** STOP .ep.installed for |$*| ***** \n" - -.sh.installed : # Create and install a "fake" encap package - @printf "***** START .sh.installed for |$*| ***** \n" - ( ${EPKG} -q -r ${ENCAPDIR}/$* || true ) - ( rm -rf ${ENCAPDIR}/$* || true ) - chmod 755 ./$*.sh - ./$*.sh - ${EPKG} -q -i ${ENCAPDIR}/$* - test -h ${BASEDIR}/var/encap/$* - touch $*.installed - @printf "***** STOP .sh.installed for |$*| ***** \n" - -.installed.packaged : # Create .tar.gz encap packages for distribution - @printf "***** START .installed.packaged for |$*| ***** \n" - ( rm ${ENCAPDIR}/$*-*.tar.gz || true ) - ( cd ${ENCAPDIR} && ${MKENCAP} -e $* || true ) - cd ${ENCAPDIR} && ${MKENCAP} -c $* - mv ${ENCAPDIR}/$*-encap-*.tar.gz . - touch $*.packaged - @printf "***** STOP .installed.packaged for |$*| ***** \n" - -all : - ( $(MAKE) install > make.log 2>&1 && $(MAKE) encaps >> make.log 2>&1 ) & - -install : ${EPKG} ${MKENCAP} ${BCFG2}.installed - -encaps : ${EPKG} ${MKENCAP} ${BCFG2}.packaged - -rename : encaps - test "$${OS}x" != "x" - for EARCHIVE in `ls *-encap-*.tar.gz`; do \ - mv $${EARCHIVE} `printf $${EARCHIVE} | awk -F- '{$$NF = "OSDIST.tar.gz" ; print}' | sed s:\ :-:g | sed s:OSDIST:\$${OS}:g` ; \ - done - -clean : - ( rm *.log || true ) - ( rm *.packaged || true ) - ( rm *.gz || true ) - ( rm *~ || true ) - -uninstall : clean - ( rm *.installed || true ) - ( ${EPKG} -q -r ${ENCAPDIR}/bcfg2-* || true ) - ( rm -rf ${ENCAPDIR}/bcfg2-* || true ) - ( rm -rf ${BASEDIR}/lib/bcfg2 || true ) - -bcfg2only : - $(MAKE) -t; sleep 2; touch $(BCFG2).ep; $(MAKE) - -${ZLIB}.installed : ${M4}.installed -${LIBICONV}.installed : ${ZLIB}.installed -${GETTEXT}.installed : ${LIBICONV}.installed -${PKG-CONFIG}.installed : ${GETTEXT}.installed -${OPENSSL}.installed : ${PKG-CONFIG}.installed -${LIBSTDCXX}.installed : ${OPENSSL}.installed -${LIBGCC}.installed : ${LIBSTDCXX}.installed -${PYTHON}.installed : ${LIBGCC}.installed -${PYREX}.installed : ${PYTHON}.installed -${PYOPENSSL}.installed : ${PYREX}.installed -${LIBXML2}.installed : ${PYOPENSSL}.installed -${LIBXSLT}.installed : ${LIBXML2}.installed -${LXML}.installed : ${LIBXSLT}.installed -${BCFG2}.installed : ${LXML}.installed - -${LIBICONV}.packaged : ${ZLIB}.packaged -${GETTEXT}.packaged : ${LIBICONV}.packaged -${OPENSSL}.packaged : ${GETTEXT}.packaged -${LIBSTDCXX}.packaged : ${OPENSSL}.packaged -${LIBGCC}.packaged : ${LIBSTDCXX}.packaged -${PYTHON}.packaged : ${LIBGCC}.packaged -${PYOPENSSL}.packaged : ${PYTHON}.packaged -${LIBXML2}.packaged : ${PYOPENSSL}.packaged -${LIBXSLT}.packaged : ${LIBXML2}.packaged -${LXML}.packaged : ${LIBXSLT}.packaged -${BCFG2}.packaged : ${LXML}.packaged diff --git a/encap/README b/encap/README index bdb4cd1ab..964fd2341 100644 --- a/encap/README +++ b/encap/README @@ -1,30 +1,50 @@ +tools-build +----------- +Tools used during the build process; should be built before anything else. + * m4 - The macro processor, used by mkencap, which is used by everything. + * makeself - A utility to create self-extracting archives, used by the + top-level Makefile to create the bcfg2-*.run distributions. + * patch - Used to patch daemontools and ostiary sources before they build. + +bcfg2-client +------------ +bcfg2 gettext libgcc libiconv libstdc++ libxml2 libxslt lxml openssl pkg-config pyopenssl pyrex python zlib + +bcfg2-cheetah +------------- +The cheetah python-powered templating system. Used as a build tool by bcfg2-site, and by bcfg2-server. Build order: + bcfg2-python-apt ---------------- -Needed for bcfg2 clients that use the "Advanced Packaging Tool" (apt). +Needed for bcfg2 clients that use the "Advanced Packaging Tool" (apt), such as Debian and Ubuntu. bcfg2-server ------------ -Encaps for bcfg2 server deps. Only for GNU/Linux. +Gamin (and glib, upon which it depends), which are needed by the bcfg2 server. Only for GNU/Linux. bcfg2-site ---------- Tools to make an encap package with your site-specific bcfg2.conf, custom bcfg2 generators, bcfg2 client run frequency, etc. -daemontools - http://cr.yp.to/daemontools.html ----------------------------------------------- -D. J. Bernstein's daemontools - a collection of tools for managing -UNIX services the same way across all UNIX platforms. May be useful to -set up one-time run of bcfg2 client at startup, or to run ostiary. - -epkg - http://www.encap.org/epkg --------------------------------- -Mark D. Roth's epkg - an encap pacakage manager. Needed to build the -*.ep and *.sh files, although in most cases epkg binaries for your -platform will already exist. - -ostiary - http://ingles.homeunix.org/software/ost -------------------------------------------------- -Ray Ingles' ostiary - simple, secure remote script execution. May be -useful if you like/are used to being able to kick off a config update -on a config client from a config server, like with cfengine. +tools-deploy/daemontools +------------------------ +D. J. Bernstein's daemontools - a collection of tools for managing UNIX services the same way across all UNIX platforms. Used by bcfg2-site to run ostiary and bcfg2-client; may also be used to run bcfg2-server. + +tools-deploy/ostiary +-------------------- +Ray Ingles' ostiary - simple, secure remote script execution. Used by bcfg2-site to enable the remote kickoff of bcfg2-client runs. + +bcfg2-python-apt +---------------- +Before building this, make sure that you have these libraries installed: + * /usr/lib/libapt-pkg* (Part of the "apt" package on Debian) + * /usr/lib/libapt-inst* (Part of the "apt-utils" package on Debian) + +You also must have the "libapt-pkg-dev" package installed. + +To see if your Debian variant is supported, do "grep ifeq Makefile" and see if +any of those strings match "cat /etc/issue". + +It should be pretty trivial to add new Debian platforms; if you have any +issues, mail the bcfg2-dev list or open a ticket. diff --git a/encap/TODO b/encap/TODO index 2f4a45b71..5c4978aca 100644 --- a/encap/TODO +++ b/encap/TODO @@ -1,18 +1,16 @@ - * bcfg2-site: create/test - * ostiary setup / bcfg2 integration scripts - * envdir overrides - * etc. + * Add daemontools bcfg2-client service startup to either bcfg2-site, or + makeself install script. - * Double-check all permissions, and make sure they are not effected by umask + * makeself-dist: create/test + * Handle TODO items in ./src/encap-profiles/makeself-2.1.4.ep + * End result will be .run distribution that installs all client stuff + * gamin and glib (server requirements) will be manual install items - * Update Makefile to refer to make/install tools/bcfg2-python-apt - on apt-using platforms (Debian, Ubuntu etc.) - also mention false error - message you will get if you don't in the README. - - * Big README update, mention ostiary, daemontools, bcfg2-site etc. - - * Handle removals nicely (preremove/postremove scripts) + * Double-check all permissions, and make sure they are not effected by + the environment's umask + * Big documentation update + * Build everywhere, basic test and post binaries * Announce to mailing list: @@ -20,3 +18,8 @@ * encap support for Solaris (sparc and x86) * Binary epkg archive at http://www.pobox.com/users/dclark/mirror/bcfg2-encaps + + * Fix epkg README/Makefile links on dclark.us + + * Handle removals nicely (preremove/postremove scripts) + * Work towards full compliance with encap 2.1 spec diff --git a/encap/VERSION b/encap/VERSION index aec258df7..b63ba696b 100644 --- a/encap/VERSION +++ b/encap/VERSION @@ -1 +1 @@ -0.8 +0.9 diff --git a/encap/src/Makefile b/encap/src/Makefile new file mode 100644 index 000000000..4bf91fb32 --- /dev/null +++ b/encap/src/Makefile @@ -0,0 +1,19 @@ +# $Id$ + +export SHELL = /bin/sh + +.PHONY : test log all installconfig dist + +log : + ( $(MAKE) all > ./make.log 2>&1 ) & + +all : + $(MAKE) -C ./encap-profiles all + $(MAKE) -C ./bcfg2-site all + $(MAKE) dist + +installconfig : + $(MAKE) -C ./bcfg2-site install + +dist : + diff --git a/encap/src/bcfg2-site/Makefile b/encap/src/bcfg2-site/Makefile index e42ff2eb6..1f9063d9e 100644 --- a/encap/src/bcfg2-site/Makefile +++ b/encap/src/bcfg2-site/Makefile @@ -7,7 +7,7 @@ CHEETAH = /usr/local/lib/bcfg2/bin/cheetah # Main -.PHONY : all clean fill copy fix encap test cheetah +.PHONY : all clean distclean fill copy fix encap install test cheetah .SUFFIXES : BD = /usr/local @@ -23,36 +23,46 @@ clean : done; \ done +distclean : clean + -rm *-encap-*.tar.gz + fill : clean $(CHEETAH) fill -R --oext out copy : fill EN=`cat bcfg2-site-RENAME/encapname.out` && \ - ( test ! -d $$ED/bcfg2-site-$${EN} || rm -rf $$ED/bcfg2-site-$${EN} ) && \ + ( test ! -d $(ED)/bcfg2-site-$${EN} || rm -rf $(ED)/bcfg2-site-$${EN} ) && \ for SRC in `find bcfg2-site-RENAME | grep -v svn | grep -v tmpl`; do \ - DEST=$$ED/`printf "$$SRC" | sed s/RENAME/$$EN/g | sed s/\.out//g`; \ + DEST=$(ED)/`printf "$$SRC" | sed s/RENAME/$$EN/g | sed s/\.out//g`; \ if [ -d $$SRC ]; then mkdir $$DEST; else cp $$SRC $$DEST; fi; \ done fix : copy - EN="$$ED/bcfg2-site-`cat bcfg2-site-RENAME/encapname.out`" && \ + EN="$(ED)/bcfg2-site-`cat bcfg2-site-RENAME/encapname.out`" && \ chown -R 0 $$EN && chgrp -R 0 $$EN && \ find $$EN -type d | xargs -n1 chmod 0755 && \ find $$EN -type f | xargs -n1 chmod 0644 && \ chmod 0600 $$EN/etc/ostiary.cfg && \ chmod 0600 $$EN/etc/bcfg2.conf && \ chmod 0755 $$EN/sbin/ost-bcfg2.sh && \ - chmod 0755 $$EN/postinstall && \ - chmod 0755 $$EN/preinstall + chmod 0755 $$EN/postinstall encap : fix EN="bcfg2-site-`cat bcfg2-site-RENAME/encapname.out`" && \ - cd $$ED && \ + cd $(ED) && \ ( test ! -f $${EN}-encap-*.tar.gz || rm $${EN}-encap-*.tar.gz ) && \ mkencap -c $$EN EN="bcfg2-site-`cat bcfg2-site-RENAME/encapname.out`" && \ - mv $$ED/$${EN}-encap-*.tar.gz . + mv $(ED)/$${EN}-encap-*.tar.gz ./ +install : fix + -(EN="bcfg2-site-`cat bcfg2-site-RENAME/encapname.out`" && \ + epkg -q -r $(ED)/$$EN) + EN="bcfg2-site-`cat bcfg2-site-RENAME/encapname.out`" && \ + cd $(ED) && \ + epkg -q -i $(ED)/$$EN && \ + test -h $(BD)/var/encap/$$EN + test : : $(PATH) $(CHEETAH) test diff --git a/encap/src/bcfg2-site/bcfg2-site-RENAME/encapinfo.tmpl b/encap/src/bcfg2-site/bcfg2-site-RENAME/encapinfo.tmpl index e6af738ac..f54cb1e18 100644 --- a/encap/src/bcfg2-site/bcfg2-site-RENAME/encapinfo.tmpl +++ b/encap/src/bcfg2-site/bcfg2-site-RENAME/encapinfo.tmpl @@ -7,3 +7,5 @@ description bcfg2-site-${SITE_SHORTNAME} - bcfg2 configuration for ${SITE_NAME} prereq pkgspec >= bcfg2-0.8.2 prereq pkgspec >= daemontools-0.76 prereq pkgspec >= ostiary-3.4 +exclude etc +exclude sbin diff --git a/encap/src/bcfg2-site/bcfg2-site-RENAME/etc/default/bcfg2-client/.SENTINEL_SITE b/encap/src/bcfg2-site/bcfg2-site-RENAME/etc/default/bcfg2-client/.SENTINEL_SITE deleted file mode 100644 index e69de29bb..000000000 diff --git a/encap/src/bcfg2-site/bcfg2-site-RENAME/etc/default/bcfg2-server/.SENTINEL_SITE b/encap/src/bcfg2-site/bcfg2-site-RENAME/etc/default/bcfg2-server/.SENTINEL_SITE deleted file mode 100644 index e69de29bb..000000000 diff --git a/encap/src/bcfg2-site/bcfg2-site-RENAME/mkinstalldirs b/encap/src/bcfg2-site/bcfg2-site-RENAME/mkinstalldirs new file mode 100755 index 000000000..0801ec2c9 --- /dev/null +++ b/encap/src/bcfg2-site/bcfg2-site-RENAME/mkinstalldirs @@ -0,0 +1,32 @@ +#! /bin/sh +# mkinstalldirs --- make directory hierarchy +# Author: Noah Friedman +# Created: 1993-05-16 +# Last modified: 1994-03-25 +# Public domain + +errstatus=0 + +for file in ${1+"$@"} ; do + set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` + shift + + pathcomp= + for d in ${1+"$@"} ; do + pathcomp="$pathcomp$d" + case "$pathcomp" in + -* ) pathcomp=./$pathcomp ;; + esac + + if test ! -d "$pathcomp"; then + echo "mkdir $pathcomp" 1>&2 + mkdir "$pathcomp" || errstatus=$? + fi + + pathcomp="$pathcomp/" + done +done + +exit $errstatus + +# mkinstalldirs ends here diff --git a/encap/src/bcfg2-site/bcfg2-site-RENAME/postinstall b/encap/src/bcfg2-site/bcfg2-site-RENAME/postinstall index e69de29bb..4ed875e4c 100755 --- a/encap/src/bcfg2-site/bcfg2-site-RENAME/postinstall +++ b/encap/src/bcfg2-site/bcfg2-site-RENAME/postinstall @@ -0,0 +1,81 @@ +#!/bin/sh -e + +umask 002 +BASEDIR="${ENCAP_TARGET}" # Usually /usr/local +PKGDIR="${ENCAP_SOURCE}/${ENCAP_PKGNAME}" # Ususally /usr/local/encap/ +LOG="${PKGDIR}/postinstall.log" +MKINSTALLDIRS="${PKGDIR}/mkinstalldirs" +exec > $LOG 2>&1 + +printf "Running ${ENCAP_PKGNAME} postinstall script...\n" +date + +chmod 755 ${MKINSTALLDIRS} +${MKINSTALLDIRS} "${BASEDIR}/etc/default/bcfg2-client/env" +${MKINSTALLDIRS} "${BASEDIR}/etc/default/bcfg2-server/env" +${MKINSTALLDIRS} "${BASEDIR}/sbin" + +rmcp() { + SRCFILENAME="`basename ${1}`" + if [ -d "${2}" ]; then + DESTDIRNAME="$2" + else + DESTDIRNAME="`dirname ${2}`" + fi + TARGETNAME="$DESTDIRNAME/$SRCFILENAME" + if [ -h "$TARGETNAME" ]; then rm "$TARGETNAME"; fi + if [ -f "$TARGETNAME" ]; then rm "$TARGETNAME"; fi + cp "$1" "$2" +} + +if [ -f ${BASEDIR}/etc/default/bcfg2-client/.SENTINEL_BCFG2 ]; then + printf "INFO: bcfg2 client options have been updated by bcfg2 -\n" + printf "INFO: not replacing that configuration.\n" +elif [ -f ${BASEDIR}/etc/default/bcfg2-client/.SENTINEL_SITE ]; then + printf "INFO: bcfg2 client options have been previously updated -\n" + printf "INFO: not replacing that configuration.\n" +else + DIR="etc/default/bcfg2-client" + rmcp $PKGDIR/$DIR/env/RUN_INTERVAL_SECONDS ${BASEDIR}/$DIR/env/ + rmcp $PKGDIR/$DIR/env/OPTIONS ${BASEDIR}/$DIR/env/ + touch ${BASEDIR}/$DIR/.SENTINEL_SITE +fi + +if [ -f ${BASEDIR}/etc/default/bcfg2-server/.SENTINEL_BCFG2 ]; then + printf "INFO: bcfg2 server options have been updated by bcfg2 -\n" + printf "INFO: not replacing that configuration.\n" +elif [ -f ${BASEDIR}/etc/default/bcfg2-server/.SENTINEL_SITE ]; then + printf "INFO: bcfg2 server options have been previously updated -\n" + printf "INFO: not replacing that configuration.\n" +else + DIR="etc/default/bcfg2-server" + rmcp $PKGDIR/$DIR/env/OPTIONS ${BASEDIR}/$DIR/env/ + touch ${BASEDIR}/$DIR/.SENTINEL_SITE +fi + +if [ -f ${BASEDIR}/etc/.SENTINEL_BCFG2 ]; then + printf "INFO: bcfg2.conf and/or ostiary.cfg may have been updated by\n" + printf "INFO: bcfg2 - not replacing that configuration.\n" +elif [ -f ${BASEDIR}/etc/.SENTINEL_SITE ]; then + printf "INFO: bcfg2.conf and/or ostiary.cfg may have been previously\n" + printf "INFO: updated - not replacing that configuration.\n" +else + rmcp $PKGDIR/etc/bcfg2.conf ${BASEDIR}/etc/ + rmcp $PKGDIR/etc/ostiary.cfg ${BASEDIR}/etc/ + touch ${BASEDIR}/etc/.SENTINEL_SITE +fi + +if [ -f ${BASEDIR}/sbin/.SENTINEL_BCFG2 ]; then + printf "INFO: ost-bcfg2.sh may have been updated by bcfg2 -\n" + printf "INFO: not replacing that configuration with this script.\n" +elif [ -f ${BASEDIR}/sbin/.SENTINEL_SITE ]; then + printf "INFO: ost-bcfg2.sh may have been previously updated -\n" + printf "INFO: not replacing that configuration with this script.\n" +else + rmcp $PKGDIR/sbin/ost-bcfg2.sh ${BASEDIR}/sbin/ + touch ${BASEDIR}/sbin/.SENTINEL_SITE +fi + +printf "Finished ${ENCAP_PKGNAME} postinstall script.\n" + +exit 0 diff --git a/encap/src/bcfg2-site/bcfg2-site-RENAME/preinstall b/encap/src/bcfg2-site/bcfg2-site-RENAME/preinstall deleted file mode 100755 index e69de29bb..000000000 diff --git a/encap/src/bcfg2-site/site-settings.conf b/encap/src/bcfg2-site/site-settings.conf deleted file mode 100644 index c29ab36e2..000000000 --- a/encap/src/bcfg2-site/site-settings.conf +++ /dev/null @@ -1,46 +0,0 @@ -###### -###### Set these variables as appropriate for your site -###### -#### -#### Site Information -#### -#set global $ADMIN_NAME = "Local Admin Contact" -#set global $ADMIN_EMAIL = "tickets@localhost.localdomain.com" -#set global $SITE_NAME = "localdomain.com" -## SITE_SHORTNAME should be a single word with no punctuation -#set global $SITE_SHORTNAME = "localdomain" -## SITE_VERSION should be the version of this file, starting at 1 -#set global $SITE_VERSION = "1" -#### -#### Paths, Variables, and Passwords -#### -#set global $SENDMAILPATH = "/usr/sbin/sendmail" -#set global $BCFG2_SERVER = "config.localdomain.com" -#set global $BCFG2_PORT = "6" -#set global $OSTIARY_PORT = "7" -#set global $BCFG2_CLIENT_RUN_INTERVAL_SECONDS = "3600" -## Initial options for bcfg(1). The bcfg2 client is started with these options -## on installation and periodically based on BCFG2_CLIENT_RUN_INTERVAL_SECONDS, -## so you probably want to include the "-n" (dry-run mode) flag, unless you -## already have a good configuration in place. You can then change the config -## file /usr/local/etc/default/bcfg2-client/env/OPTIONS via the bcfg2 "Cfg" -## functionality (possibly by kicking off a non-dry from the bcfg2 server using -## ostiary, or just by running bcfg2 manually on the client) to run in non-dry- -## run mode. -#set global $BCFG2_CLIENT_OPTIONS = "-q -v -d -n" -## Initial options for bcfg2-server(8). Note that bcfg2-server is not fully -## configured by bcfg2-site; you need to edit /usr/local/etc/bcfg2.conf to -## include the "[server]" stanza and appropriate values, as well as a "key =" -## line in the "[communications]" stanza (see bcfg2 doc for details). -#set global $BCFG2_SERVER_OPTIONS = "-v" -## You can set passwords here, and you will not be prompted for them at -## install time; however you will then have to treat your bcfg2-site -## distribution as equivalent to the bcfg2 server and ostiary passwords. -## To be prompted for passwords at install time, make these empty string ("") -#set global $BCFG2_PASSWORD = "" -#set global $OSTIARY_PASSWORD = "" -###### -###### Automatically-set variables - you shouldn't have to touch these. -###### -#from time import localtime, strftime -#set global $DATE = strftime("%a %b %d %H:%M:%S %Z %Y", localtime()) diff --git a/encap/src/bcfg2-site/site-settings.conf-example b/encap/src/bcfg2-site/site-settings.conf-example new file mode 100644 index 000000000..c29ab36e2 --- /dev/null +++ b/encap/src/bcfg2-site/site-settings.conf-example @@ -0,0 +1,46 @@ +###### +###### Set these variables as appropriate for your site +###### +#### +#### Site Information +#### +#set global $ADMIN_NAME = "Local Admin Contact" +#set global $ADMIN_EMAIL = "tickets@localhost.localdomain.com" +#set global $SITE_NAME = "localdomain.com" +## SITE_SHORTNAME should be a single word with no punctuation +#set global $SITE_SHORTNAME = "localdomain" +## SITE_VERSION should be the version of this file, starting at 1 +#set global $SITE_VERSION = "1" +#### +#### Paths, Variables, and Passwords +#### +#set global $SENDMAILPATH = "/usr/sbin/sendmail" +#set global $BCFG2_SERVER = "config.localdomain.com" +#set global $BCFG2_PORT = "6" +#set global $OSTIARY_PORT = "7" +#set global $BCFG2_CLIENT_RUN_INTERVAL_SECONDS = "3600" +## Initial options for bcfg(1). The bcfg2 client is started with these options +## on installation and periodically based on BCFG2_CLIENT_RUN_INTERVAL_SECONDS, +## so you probably want to include the "-n" (dry-run mode) flag, unless you +## already have a good configuration in place. You can then change the config +## file /usr/local/etc/default/bcfg2-client/env/OPTIONS via the bcfg2 "Cfg" +## functionality (possibly by kicking off a non-dry from the bcfg2 server using +## ostiary, or just by running bcfg2 manually on the client) to run in non-dry- +## run mode. +#set global $BCFG2_CLIENT_OPTIONS = "-q -v -d -n" +## Initial options for bcfg2-server(8). Note that bcfg2-server is not fully +## configured by bcfg2-site; you need to edit /usr/local/etc/bcfg2.conf to +## include the "[server]" stanza and appropriate values, as well as a "key =" +## line in the "[communications]" stanza (see bcfg2 doc for details). +#set global $BCFG2_SERVER_OPTIONS = "-v" +## You can set passwords here, and you will not be prompted for them at +## install time; however you will then have to treat your bcfg2-site +## distribution as equivalent to the bcfg2 server and ostiary passwords. +## To be prompted for passwords at install time, make these empty string ("") +#set global $BCFG2_PASSWORD = "" +#set global $OSTIARY_PASSWORD = "" +###### +###### Automatically-set variables - you shouldn't have to touch these. +###### +#from time import localtime, strftime +#set global $DATE = strftime("%a %b %d %H:%M:%S %Z %Y", localtime()) diff --git a/encap/src/encap-profiles/Makefile b/encap/src/encap-profiles/Makefile new file mode 100644 index 000000000..357758f02 --- /dev/null +++ b/encap/src/encap-profiles/Makefile @@ -0,0 +1,164 @@ +# $Id$ + +.PHONY : test log all install clean distclean uninstall encaps rename bcfg2only +.SUFFIXES : +.SUFFIXES : .ep .sh .installed .packaged .d + +export BASEDIR = /usr/local +export ENCAPDIR := ${BASEDIR}/encap +export EPKG := ${BASEDIR}/bin/epkg +export MKENCAP := ${BASEDIR}/bin/mkencap +export SHELL = /bin/sh +srcdir = . +export EP2TARGET := $(srcdir)/ep2target + +BCFG2 := $(basename $(wildcard bcfg2-[0-9].[0-9]*.ep)) +BCFG2_CHEETAH := $(basename $(wildcard bcfg2-cheetah-[0-9].[0-9]*.ep)) +BCFG2_CHEETAH_DOC := $(basename $(wildcard bcfg2-cheetah-doc-*.ep)) +BCFG2_GAMIN := $(basename $(wildcard bcfg2-gamin-*.ep)) +BCFG2_GETTEXT := $(basename $(wildcard bcfg2-gettext-*.ep)) +BCFG2_GLIB := $(basename $(wildcard bcfg2-glib-*.ep)) +BCFG2_LIBGCC := $(basename $(wildcard bcfg2-libgcc-*.sh)) +BCFG2_LIBICONV := $(basename $(wildcard bcfg2-libiconv-*.ep)) +BCFG2_LIBSTDCXX := $(basename $(wildcard bcfg2-libstdc++-*.sh)) +BCFG2_LIBXML2 := $(basename $(wildcard bcfg2-libxml2-*.ep)) +BCFG2_LIBXSLT := $(basename $(wildcard bcfg2-libxslt-*.ep)) +BCFG2_LXML := $(basename $(wildcard bcfg2-lxml-*.ep)) +BCFG2_OPENSSL := $(basename $(wildcard bcfg2-openssl-*.ep)) +BCFG2_PKG_CONFIG := $(basename $(wildcard bcfg2-pkg-config-*.ep)) +BCFG2_PYOPENSSL := $(basename $(wildcard bcfg2-pyopenssl-*.ep)) +BCFG2_PYREX := $(basename $(wildcard bcfg2-pyrex-*.ep)) +BCFG2_PYTHON := $(basename $(wildcard bcfg2-python-[0-9].[0-9]*.ep)) +BCFG2_ZLIB := $(basename $(wildcard bcfg2-zlib-*.ep)) +DAEMONTOOLS := $(basename $(wildcard daemontools-[0-9].[0-9]*.ep)) +DAEMONTOOLS_DOC := $(basename $(wildcard daemontools-doc-*.ep)) +M4 := $(basename $(wildcard m4-*.sh)) +MAKESELF := $(basename $(wildcard makeself-*.ep)) +OSTIARTY := $(basename $(wildcard ostiary-[0-9].[0-9]*.ep)) +OSTIARTY_DOC := $(basename $(wildcard ostiary-doc-*.ep)) +PATCH := $(basename $(wildcard patch-*.ep)) + +sources_ep := $(sort $(BCFG2) $(BCFG2_CHEETAH) $(BCFG2_CHEETAH_DOC) $(BCFG2_GETTEXT) $(BCFG2_LIBICONV) $(BCFG2_LIBXML2) $(BCFG2_LIBXSLT) $(BCFG2_LXML) $(BCFG2_OPENSSL) $(BCFG2_PKG_CONFIG) $(BCFG2_PYOPENSSL) $(BCFG2_PYREX) $(BCFG2_PYTHON) $(BCFG2_ZLIB) $(DAEMONTOOLS) $(DAEMONTOOLS_DOC) $(MAKESELF) $(OSTIARTY) $(OSTIARTY_DOC) $(PATCH)) + +sources_sh := $(sort $(BCFG2_LIBGCC) $(BCFG2_LIBSTDCXX) $(M4)) + +# Only compile bcfg2-glib and bcfg2-gamin (needed by bcfg2 server) on Linux +# (Gamin only supports Linux), and only compile bcfg2-python-apt on known +# Debian and Ubuntu systems (as python-apt is distribution-specific) +UNAME := $(shell uname) + +ifeq ($(UNAME),Linux) +sources_ep += $(BCFG2_GLIB) $(BCFG2_GAMIN) +DISTRO := $(shell cat /etc/issue | head -1) +endif + +ifeq ($(DISTRO),Debian GNU/Linux 3.1 \n \l) +BCFG2_PYTHON_APT = bcfg2-python-apt-0.5.10 +OS ?= linux_debian_sarge +endif + +ifeq ($(DISTRO),Debian GNU/Linux testing/unstable \n \l) +BCFG2_PYTHON_APT = bcfg2-python-apt-0.6.19 +OS ?= linux_debian_sid +endif + +ifeq ($(DISTRO),Ubuntu 6.06.1 LTS \n \l) +BCFG2_PYTHON_APT = bcfg2-python-apt-0.6.16.2ubuntu8 +OS ?= linux_ubuntu_dapper +endif + +ifdef BCFG2_PYTHON_APT +sources_ep += $(BCFG2_PYTHON_APT) +endif + +# List of all sources... +sources := $(sort $(sources_ep) $(sources_sh)) + +%.installed : %.ep # Clean, compile and install an encap package + @printf "***** START .ep.installed for |$*| ***** \n" + -$(EPKG) -q -r $(ENCAPDIR)/$* + -rm -rf $(ENCAPDIR)/$* + -$(MKENCAP) -m /usr/local/bin/m4 -b -DUP $(srcdir)/$*.ep > ./$*.log 2>&1 + -$(MKENCAP) -m /usr/local/bin/m4 -b -T $(srcdir)/$*.ep >> ./$*.log 2>&1 + $(MKENCAP) -m /usr/local/bin/m4 -b -CBI $(srcdir)/$*.ep >> ./$*.log 2>&1 + $(EPKG) -q -i $(ENCAPDIR)/$* + test -h $(BASEDIR)/var/encap/$* + touch ./$*.installed + @printf "***** STOP .ep.installed for |$*| ***** \n" + +%.installed : %.sh # Create and install a "fake" encap package + @printf "***** START .sh.installed for |$*| ***** \n" + -$(EPKG) -q -r $(ENCAPDIR)/$* + -rm -rf $(ENCAPDIR)/$* + chmod 755 $(srcdir)/$*.sh && $(srcdir)/$*.sh + $(EPKG) -q -i $(ENCAPDIR)/$* + test -h $(BASEDIR)/var/encap/$* + touch ./$*.installed + @printf "***** STOP .sh.installed for |$*| ***** \n" + +%.packaged : %.installed # Create .tar.gz encap packages + @printf "***** START .installed.packaged for |$*| ***** \n" + -rm $(ENCAPDIR)/$*-*.tar.gz + -(cd $(ENCAPDIR) && $(MKENCAP) -e $*) + -(cd $(ENCAPDIR) && $(MKENCAP) -c $*) + mv $(ENCAPDIR)/$*-encap-*.tar.gz ./ + touch ./$*.packaged + @printf "***** STOP .installed.packaged for |$*| ***** \n" + +%.d : %.ep # Create dependancy files from .ep files + @printf "***** START .d.ep for |$*| ***** \n" + chmod 755 $(EP2TARGET) && $(EP2TARGET) $< > $@ + @printf "***** STOP .d.ep for |$*| ***** \n" + +%.d : %.sh # Create dependancy files from .sh files + @printf "***** START .d.sh for |$*| ***** \n" + chmod 755 $(EP2TARGET) && $(EP2TARGET) $< > $@ + @printf "***** STOP .d.sh for |$*| ***** \n" + +log : + ( $(MAKE) install > ./make.log 2>&1 \ + && $(MAKE) encaps >> ./make.log 2>&1 \ + && $(MAKE) rename >> ./make.log 2>&1 ) & + +all : install encaps rename + +.DELETE_ON_ERROR : # delete the target of a rule if it has changed and its + # commands exit with a nonzero exit status + +install : $(EPKG) $(MKENCAP) $(EP2TARGET) $(addsuffix .installed,$(sources)) + +encaps : $(EPKG) $(MKENCAP) $(EP2TARGET) $(addsuffix .packaged,$(sources)) + +rename : encaps + if [ "$(OS)x" != "x" ]; then OS="$(OS)"; fi && \ + if [ "$${OS}x" != "x" ]; then \ + for OLDNAME in `ls ./*-encap-*.tar.gz`; do \ + NEWNAME="`printf $${OLDNAME} \ + | awk -F- '{$$NF = "OSDIST.tar.gz" ; print}' \ + | sed s:\ :-:g | sed s:OSDIST:\$${OS}:g`" ; \ + if [ "$${OLDNAME}x" != "$${NEWNAME}x" ]; then \ + mv ./$${OLDNAME} ./$${NEWNAME}; \ + fi; \ + done; \ + fi + +clean : + -(rm ./*.log; rm ./*.packaged; rm ./*.gz; rm ./*~) + +distclean : clean + -rm ./*.d + +uninstall : distclean + -(find $(BASEDIR)/lib/bcfg2 | grep "\.pyc" | xargs -n1 rm) + -(ENCAPS="m4 patch daemontools makeself ostiary bcfg2"; \ + for ENCAP in $${ENCAPS}; do \ + $(EPKG) -q -r $(ENCAPDIR)/$${ENCAP}-*; \ + rm -rf $(ENCAPDIR)/$${ENCAP}-*; \ + rm ./$${ENCAP}-*.installed; \ + done) + test ! -d $(BASEDIR)/lib/bcfg2 + +bcfg2only : + $(MAKE) -t; sleep 2; touch $(srcdir)/$(BCFG2).ep; $(MAKE) + +include $(addsuffix .d,$(sources)) diff --git a/encap/src/encap-profiles/bcfg2-0.8.2.ep b/encap/src/encap-profiles/bcfg2-0.8.2.ep deleted file mode 100644 index cb8b99ecf..000000000 --- a/encap/src/encap-profiles/bcfg2-0.8.2.ep +++ /dev/null @@ -1,444 +0,0 @@ - - - - - - - - - - -PLATFORM_IF_MATCH(linux) -PLATFORM_ELSE - -PLATFORM_ENDIF - - - - - - - - -: - - - -/usr/local/lib/bcfg2/bin/python setup.py build \ ---build-base=${builddir}/build - - - -/usr/local/lib/bcfg2/bin/python setup.py install \ ---prefix=${ENCAP_SOURCE}/${ENCAP_PKGNAME}/lib/bcfg2 - - - -/usr/local/lib/bcfg2/bin/python setup.py clean - - - - - - - - - - - - -&1 -printf "*** exec /command/envdir /usr/local/etc/default/bcfg2-client/env ./bcfg2-client.sh ...\n" -exec /command/envdir /usr/local/etc/default/bcfg2-client/env ./bcfg2-client.sh -]]> - -&1 -exec /command/multilog t /usr/local/var/multilog/bcfg2-client -]]> - -&1 -/command/envdir /usr/local/etc/default/bcfg2-server/env /bin/sh -c '\ - printf "*** exec /usr/local/bin/bcfg2-server ${OPTIONS} ...\n"' -exec /command/envdir /usr/local/etc/default/bcfg2-server/env /bin/sh -c '\ - exec /usr/local/bin/bcfg2-server ${OPTIONS}' -]]> - -&1 -exec /command/multilog t /usr/local/var/multilog/bcfg2-server -]]> - - ${BASEDIR}/postinstall.log 2>&1 3>&1 -else - printf "\npostinstall: already ran\n\t${BASEDIR}/b2-regexplace.sh, not running again...\n" >> ${BASEDIR}/postinstall.log -fi - -# Make sure log directories exist -test -d /usr/local/var || mkdir /usr/local/var -test -d $MULTILOG || mkdir $MULTILOG -test -d $MULTILOG/bcfg2-client || mkdir $MULTILOG/bcfg2-client -test -d $MULTILOG/bcfg2-server || mkdir $MULTILOG/bcfg2-server - -# Make sure environment directories exist -test -d /usr/local/etc || mkdir /usr/local/etc -test -d $DEFAULT || mkdir $DEFAULT -test -d $DEFAULT/bcfg2-client || mkdir $DEFAULT/bcfg2-client -test -d $DEFAULT/bcfg2-client/env || mkdir $DEFAULT/bcfg2-client/env -test -d $DEFAULT/bcfg2-server || mkdir $DEFAULT/bcfg2-server -test -d $DEFAULT/bcfg2-server/env || mkdir $DEFAULT/bcfg2-server/env - -# Put in default client environment if it didn't exist -if [ ! -f $DEFAULT/bcfg2-client/.SENTINEL ]; then - touch $DEFAULT/bcfg2-client/.SENTINEL - echo "-q -v -d -n" > $DEFAULT/bcfg2-client/env/OPTIONS - echo "3600" > $DEFAULT/bcfg2-client/env/RUN_INTERVAL_SECONDS -fi - -# Put in default server environment if it didn't exist -if [ ! -f $DEFAULT/bcfg2-server/.SENTINEL ]; then - touch $DEFAULT/bcfg2-server/.SENTINEL - echo "-v" > $DEFAULT/bcfg2-server/env/OPTIONS -fi -]]> - - - -description Bcfg2 - Provides a declarative interface to system configuration -prereq pkgspec >= bcfg2-zlib-1.2.3 -prereq pkgspec >= bcfg2-libiconv-1.9.2 -prereq pkgspec >= bcfg2-gettext-0.14.5 -prereq pkgspec >= bcfg2-openssl-0.9.8b -prereq pkgspec >= bcfg2-libstdc++-0.1 -prereq pkgspec >= bcfg2-libgcc-0.1 -prereq pkgspec >= bcfg2-python-2.4.3 -prereq pkgspec >= bcfg2-pyopenssl-0.6 -prereq pkgspec >= bcfg2-libxml2-2.6.26 -prereq pkgspec >= bcfg2-libxslt-1.1.17 -prereq pkgspec >= bcfg2-lxml-1.0.1 - - - diff --git a/encap/src/encap-profiles/bcfg2-0.8.3pre1.ep b/encap/src/encap-profiles/bcfg2-0.8.3pre1.ep new file mode 100644 index 000000000..55834df59 --- /dev/null +++ b/encap/src/encap-profiles/bcfg2-0.8.3pre1.ep @@ -0,0 +1,458 @@ + + + + + + + + + + + + + + + + + + + + + + + + +PLATFORM_IF_MATCH(linux) +PLATFORM_ELSE + +PLATFORM_ENDIF + + + + + + + + +: + + + +/usr/local/lib/bcfg2/bin/python setup.py build \ +--build-base=${builddir}/build + + + +/usr/local/lib/bcfg2/bin/python setup.py install \ +--prefix=${ENCAP_SOURCE}/${ENCAP_PKGNAME}/lib/bcfg2 + + + +/usr/local/lib/bcfg2/bin/python setup.py clean + + + + + + + + + + + + +&1 +printf "*** exec /command/envdir /usr/local/etc/default/bcfg2-client/env ./bcfg2-client.sh ...\n" +exec /command/envdir /usr/local/etc/default/bcfg2-client/env ./bcfg2-client.sh +]]> + +&1 +exec /command/multilog t /usr/local/var/multilog/bcfg2-client +]]> + +&1 +/command/envdir /usr/local/etc/default/bcfg2-server/env /bin/sh -c '\ + printf "*** exec /usr/local/bin/bcfg2-server ${OPTIONS} ...\n"' +exec /command/envdir /usr/local/etc/default/bcfg2-server/env /bin/sh -c '\ + exec /usr/local/bin/bcfg2-server ${OPTIONS}' +]]> + +&1 +exec /command/multilog t /usr/local/var/multilog/bcfg2-server +]]> + + ${BASEDIR}/postinstall.log 2>&1 3>&1 +else + printf "\npostinstall: already ran\n\t${BASEDIR}/b2-regexplace.sh, not running again...\n" >> ${BASEDIR}/postinstall.log +fi + +# Make sure log directories exist +test -d /usr/local/var || mkdir /usr/local/var +test -d $MULTILOG || mkdir $MULTILOG +test -d $MULTILOG/bcfg2-client || mkdir $MULTILOG/bcfg2-client +test -d $MULTILOG/bcfg2-server || mkdir $MULTILOG/bcfg2-server + +# Make sure environment directories exist +test -d /usr/local/etc || mkdir /usr/local/etc +test -d $DEFAULT || mkdir $DEFAULT +test -d $DEFAULT/bcfg2-client || mkdir $DEFAULT/bcfg2-client +test -d $DEFAULT/bcfg2-client/env || mkdir $DEFAULT/bcfg2-client/env +test -d $DEFAULT/bcfg2-server || mkdir $DEFAULT/bcfg2-server +test -d $DEFAULT/bcfg2-server/env || mkdir $DEFAULT/bcfg2-server/env + +# Put in default client environment if it didn't exist +if [ ! -f $DEFAULT/bcfg2-client/.SENTINEL ]; then + touch $DEFAULT/bcfg2-client/.SENTINEL + echo "-q -v -d -n" > $DEFAULT/bcfg2-client/env/OPTIONS + echo "3600" > $DEFAULT/bcfg2-client/env/RUN_INTERVAL_SECONDS +fi + +# Put in default server environment if it didn't exist +if [ ! -f $DEFAULT/bcfg2-server/.SENTINEL ]; then + touch $DEFAULT/bcfg2-server/.SENTINEL + echo "-v" > $DEFAULT/bcfg2-server/env/OPTIONS +fi +]]> + + + +description Bcfg2 - Provides a declarative interface to system configuration +prereq pkgspec >= bcfg2-zlib-1.2.3 +prereq pkgspec >= bcfg2-libiconv-1.9.2 +prereq pkgspec >= bcfg2-gettext-0.14.5 +prereq pkgspec >= bcfg2-openssl-0.9.8b +prereq pkgspec >= bcfg2-libstdc++-0.1 +prereq pkgspec >= bcfg2-libgcc-0.1 +prereq pkgspec >= bcfg2-python-2.4.3 +prereq pkgspec >= bcfg2-pyopenssl-0.6 +prereq pkgspec >= bcfg2-libxml2-2.6.26 +prereq pkgspec >= bcfg2-libxslt-1.1.17 +prereq pkgspec >= bcfg2-lxml-1.0.1 + + + diff --git a/encap/src/encap-profiles/bcfg2-cheetah-2.0rc7.ep b/encap/src/encap-profiles/bcfg2-cheetah-2.0rc7.ep index ba77108f3..956536109 100644 --- a/encap/src/encap-profiles/bcfg2-cheetah-2.0rc7.ep +++ b/encap/src/encap-profiles/bcfg2-cheetah-2.0rc7.ep @@ -7,6 +7,9 @@ pkgspec="bcfg2-cheetah-2.0rc7" > + + + +# Make "this encap is installed" sentinal file available in /usr/local/var/encap test -d var || mkdir var test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/bcfg2-cheetah-doc-0.9.16a1.ep b/encap/src/encap-profiles/bcfg2-cheetah-doc-0.9.16a1.ep index 023e0bf21..475d5070f 100644 --- a/encap/src/encap-profiles/bcfg2-cheetah-doc-0.9.16a1.ep +++ b/encap/src/encap-profiles/bcfg2-cheetah-doc-0.9.16a1.ep @@ -7,6 +7,8 @@ pkgspec="bcfg2-cheetah-doc-0.9.16a1" > + + +# Make "this encap is installed" sentinal file available in /usr/local/var/encap test -d var || mkdir var test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/bcfg2-gamin-0.1.7.ep b/encap/src/encap-profiles/bcfg2-gamin-0.1.7.ep index db2c2037d..99118d03f 100644 --- a/encap/src/encap-profiles/bcfg2-gamin-0.1.7.ep +++ b/encap/src/encap-profiles/bcfg2-gamin-0.1.7.ep @@ -7,6 +7,11 @@ pkgspec="bcfg2-gamin-0.1.7" > + + + + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/bcfg2-gettext-0.14.5.ep b/encap/src/encap-profiles/bcfg2-gettext-0.14.5.ep index eaf6b01e1..7116b0b98 100644 --- a/encap/src/encap-profiles/bcfg2-gettext-0.14.5.ep +++ b/encap/src/encap-profiles/bcfg2-gettext-0.14.5.ep @@ -7,6 +7,9 @@ pkgspec="bcfg2-gettext-0.14.5" > + + + # Make man pages available from /usr/local/lib/bcfg2/man mv lib/bcfg2/share/man lib/bcfg2/ -# Other stuff... -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} -description Gettext - Tools to produce multi-lingual messages +description gettext - tools to produce multi-lingual messages diff --git a/encap/src/encap-profiles/bcfg2-glib-2.8.6.ep b/encap/src/encap-profiles/bcfg2-glib-2.8.6.ep index 3c0103706..f20eeae32 100644 --- a/encap/src/encap-profiles/bcfg2-glib-2.8.6.ep +++ b/encap/src/encap-profiles/bcfg2-glib-2.8.6.ep @@ -7,6 +7,15 @@ pkgspec="bcfg2-glib-2.8.6" > + + + + + + + + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} -description GLib - data structure handling, portability wrappers, and interfaces +description glib - data structure handling, portability wrappers, and interfaces diff --git a/encap/src/encap-profiles/bcfg2-libiconv-1.9.2.ep b/encap/src/encap-profiles/bcfg2-libiconv-1.9.2.ep index b25f7090b..b1e534191 100644 --- a/encap/src/encap-profiles/bcfg2-libiconv-1.9.2.ep +++ b/encap/src/encap-profiles/bcfg2-libiconv-1.9.2.ep @@ -7,6 +7,8 @@ pkgspec="bcfg2-libiconv-1.9.2" > + + # Make man pages available from /usr/local/lib/bcfg2/man mv lib/bcfg2/share/man lib/bcfg2/ -# Other stuff... -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} -description Libiconv - Converts between character encodings +description libiconv - Converts between character encodings diff --git a/encap/src/encap-profiles/bcfg2-libxml2-2.6.26.ep b/encap/src/encap-profiles/bcfg2-libxml2-2.6.26.ep index 318f90787..d76256e59 100644 --- a/encap/src/encap-profiles/bcfg2-libxml2-2.6.26.ep +++ b/encap/src/encap-profiles/bcfg2-libxml2-2.6.26.ep @@ -7,6 +7,13 @@ pkgspec="bcfg2-libxml2-2.6.26" > + + + + + + + -mkdir bin 2>/dev/null || exit 0 +test -d bin || mkdir bin ln -sf ../lib/bcfg2/bin/xmllint bin/b2-xmllint -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} -description Libxml2 - XML C library for the Gnome project +description libxml2 - XML C library for the Gnome project diff --git a/encap/src/encap-profiles/bcfg2-libxslt-1.1.17.ep b/encap/src/encap-profiles/bcfg2-libxslt-1.1.17.ep index 8845c4a4f..96c3d4247 100644 --- a/encap/src/encap-profiles/bcfg2-libxslt-1.1.17.ep +++ b/encap/src/encap-profiles/bcfg2-libxslt-1.1.17.ep @@ -7,6 +7,14 @@ pkgspec="bcfg2-libxslt-1.1.17" > + + + + + + + + mv lib/bcfg2/lib/lib/python2.4 lib/bcfg2/lib rmdir lib/bcfg2/lib/lib -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} -description Libxml2 - XML C library for the Gnome project +description libxslt - XSLT C processing library diff --git a/encap/src/encap-profiles/bcfg2-lxml-1.0.1.ep b/encap/src/encap-profiles/bcfg2-lxml-1.0.1.ep index aa8e009e1..b8cc4c6fb 100644 --- a/encap/src/encap-profiles/bcfg2-lxml-1.0.1.ep +++ b/encap/src/encap-profiles/bcfg2-lxml-1.0.1.ep @@ -7,6 +7,16 @@ pkgspec="bcfg2-lxml-1.0.1" > + + + + + + + + + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/bcfg2-openssl-0.9.8b.ep b/encap/src/encap-profiles/bcfg2-openssl-0.9.8b.ep index 2fa76160b..6a5d92659 100644 --- a/encap/src/encap-profiles/bcfg2-openssl-0.9.8b.ep +++ b/encap/src/encap-profiles/bcfg2-openssl-0.9.8b.ep @@ -7,6 +7,12 @@ pkgspec="bcfg2-openssl-0.9.8b" > + + + + + + -description SSL encryption tool and library +description openssl - SSL encryption tool and library diff --git a/encap/src/encap-profiles/bcfg2-pkg-config-0.20.ep b/encap/src/encap-profiles/bcfg2-pkg-config-0.20.ep index 62db17661..5b61c9a92 100644 --- a/encap/src/encap-profiles/bcfg2-pkg-config-0.20.ep +++ b/encap/src/encap-profiles/bcfg2-pkg-config-0.20.ep @@ -7,6 +7,10 @@ pkgspec="bcfg2-pkg-config-0.20" > + + + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/bcfg2-pyopenssl-0.6.ep b/encap/src/encap-profiles/bcfg2-pyopenssl-0.6.ep index 7f9fa97f6..a2a59d562 100644 --- a/encap/src/encap-profiles/bcfg2-pyopenssl-0.6.ep +++ b/encap/src/encap-profiles/bcfg2-pyopenssl-0.6.ep @@ -7,6 +7,14 @@ pkgspec="bcfg2-pyopenssl-0.6" > + + + + + + + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/bcfg2-pyrex-0.9.4.1.ep b/encap/src/encap-profiles/bcfg2-pyrex-0.9.4.1.ep index 8fcc80449..5c411285a 100644 --- a/encap/src/encap-profiles/bcfg2-pyrex-0.9.4.1.ep +++ b/encap/src/encap-profiles/bcfg2-pyrex-0.9.4.1.ep @@ -7,6 +7,9 @@ pkgspec="bcfg2-pyrex-0.9.4.1" > + + + chmod -R o+r lib/bcfg2 -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} -description Pyrex - a Language for Writing Python Extension Modules +description pyrex - a language for writing python extension modules diff --git a/encap/src/encap-profiles/bcfg2-python-2.4.3.ep b/encap/src/encap-profiles/bcfg2-python-2.4.3.ep index f62184a08..454aeced1 100644 --- a/encap/src/encap-profiles/bcfg2-python-2.4.3.ep +++ b/encap/src/encap-profiles/bcfg2-python-2.4.3.ep @@ -7,6 +7,13 @@ pkgspec="bcfg2-python-2.4.3" > + + + + + + + /dev/null || exit 0 ln -sf ../lib/bcfg2/bin/idle bin/b2-idle ln -sf ../lib/bcfg2/bin/pydoc bin/b2-pydoc ln -sf ../lib/bcfg2/bin/python bin/b2-python -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} ]]> -description Python - Scripting language +description python - scripting language diff --git a/encap/src/encap-profiles/bcfg2-python-apt-0.5.10.ep b/encap/src/encap-profiles/bcfg2-python-apt-0.5.10.ep index 57ce35310..77955e0de 100644 --- a/encap/src/encap-profiles/bcfg2-python-apt-0.5.10.ep +++ b/encap/src/encap-profiles/bcfg2-python-apt-0.5.10.ep @@ -7,6 +7,9 @@ pkgspec="bcfg2-python-apt-0.5.10" > + + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/bcfg2-python-apt-0.6.16.2ubuntu8.ep b/encap/src/encap-profiles/bcfg2-python-apt-0.6.16.2ubuntu8.ep index 4336827ae..59f30be2c 100644 --- a/encap/src/encap-profiles/bcfg2-python-apt-0.6.16.2ubuntu8.ep +++ b/encap/src/encap-profiles/bcfg2-python-apt-0.6.16.2ubuntu8.ep @@ -1,12 +1,15 @@ - + + + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/bcfg2-python-apt-0.6.19.ep b/encap/src/encap-profiles/bcfg2-python-apt-0.6.19.ep index 448d04351..af74340ff 100644 --- a/encap/src/encap-profiles/bcfg2-python-apt-0.6.19.ep +++ b/encap/src/encap-profiles/bcfg2-python-apt-0.6.19.ep @@ -7,6 +7,9 @@ pkgspec="bcfg2-python-apt-0.6.19" > + + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/bcfg2-zlib-1.2.3.ep b/encap/src/encap-profiles/bcfg2-zlib-1.2.3.ep index cba36bfb3..3b2effc8e 100644 --- a/encap/src/encap-profiles/bcfg2-zlib-1.2.3.ep +++ b/encap/src/encap-profiles/bcfg2-zlib-1.2.3.ep @@ -7,6 +7,8 @@ pkgspec="bcfg2-zlib-1.2.3" > + + # Make man pages available from /usr/local/lib/bcfg2/man mv lib/bcfg2/share/man lib/bcfg2/ -# Other stuff... -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} -description Zlib compression library +description zlib - compression library diff --git a/encap/src/encap-profiles/daemontools-0.76.ep b/encap/src/encap-profiles/daemontools-0.76.ep index c09b67a72..c6b93c2ab 100644 --- a/encap/src/encap-profiles/daemontools-0.76.ep +++ b/encap/src/encap-profiles/daemontools-0.76.ep @@ -7,8 +7,8 @@ pkgspec="daemontools-0.76" > - + /dev/null || exit 1 -mkdir var/svc.d 2>/dev/null || exit 1 -mkdir var/svc.d/svscan 2>/dev/null || exit 1 -mkdir var/svc.d/svscan/log 2>/dev/null || exit 1 -mkdir var/encap 2>/dev/null || exit 1 +test -d var || mkdir var +test -d var/svc.d || mkdir var/svc.d +test -d var/svc.d/svscan || mkdir var/svc.d/svscan +test -d var/svc.d/svscan/log || mkdir var/svc.d/svscan/log +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/daemontools-doc-20060731.ep b/encap/src/encap-profiles/daemontools-doc-20060731.ep index dee918647..1ce5d2d3e 100644 --- a/encap/src/encap-profiles/daemontools-doc-20060731.ep +++ b/encap/src/encap-profiles/daemontools-doc-20060731.ep @@ -7,6 +7,8 @@ pkgspec="daemontools-doc-20060731" > + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/ep2target b/encap/src/encap-profiles/ep2target new file mode 100755 index 000000000..31beb6e79 --- /dev/null +++ b/encap/src/encap-profiles/ep2target @@ -0,0 +1,40 @@ +#!/bin/sh + +chomp() { + printf "$1" | sed s:^\ ::g | sed s:\ $::g +} + +cname() { + unset CTMP1 CTMP2 + for PART in $(printf "$1" | sed s:-:\ :g); do + if [ ! "`printf $PART | cut -c1 | sed s:[0-9]:0:g`x" = "0x" ]; then + CTMP1="${CTMP1} ${PART}" + fi + done + CTMP2="`chomp "$CTMP1" | sed s:\ :_:g | sed s:\+:X:g | tr [a-z] [A-Z]`" + printf "\$(%s)%s" "`basename "$CTMP2"`" "$2" +} + +builddeps() { + unset DEPSTMP + for LINE in `grep " ${ENCAP_PKGNAME}.ep << EOF -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/makeself-2.1.4.ep b/encap/src/encap-profiles/makeself-2.1.4.ep index 8e8c5f2b5..fa64e1da8 100644 --- a/encap/src/encap-profiles/makeself-2.1.4.ep +++ b/encap/src/encap-profiles/makeself-2.1.4.ep @@ -7,6 +7,8 @@ pkgspec="makeself-2.1.4" > + + - + diff --git a/encap/src/encap-profiles/ostiary-doc-20060801.ep b/encap/src/encap-profiles/ostiary-doc-20060801.ep index 3b0251f2e..6ffb698be 100644 --- a/encap/src/encap-profiles/ostiary-doc-20060801.ep +++ b/encap/src/encap-profiles/ostiary-doc-20060801.ep @@ -7,6 +7,8 @@ pkgspec="ostiary-doc-20060801" > + + -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} diff --git a/encap/src/encap-profiles/patch-2.5.9.ep b/encap/src/encap-profiles/patch-2.5.9.ep index c6e2f6b69..18ce80d2b 100644 --- a/encap/src/encap-profiles/patch-2.5.9.ep +++ b/encap/src/encap-profiles/patch-2.5.9.ep @@ -42,13 +42,14 @@ PLATFORM_ENDIF -mkdir var 2>/dev/null || exit 0 -mkdir var/encap 2>/dev/null || exit 0 +# Make "this encap is installed" sentinal file available in /usr/local/var/encap +test -d var || mkdir var +test -d var/encap || mkdir var/encap touch var/encap/${ENCAP_PKGNAME} -description patch - Apply a diff file to an original +description patch - apply a diff file to an original -- cgit v1.2.3-1-g7c22