diff -r 71503088f51b -r f880f219c566 openpkg/README --- a/openpkg/README Tue Jul 31 12:12:54 2012 +0200 +++ b/openpkg/README Tue Jul 31 12:23:42 2012 +0200 @@ -1,52 +1,60 @@ - OpenPKG Boostrap Package Source Tree - ==================================== + OpenPKG Framework Bootstrap Package, Source Tree + ================================================ - This is the source code tree for the OpenPKG bootstrap package. What - you find here is rather complex and tricky stuff, so don't be confused - if you don't understand everything immediately. + This is the source tree for the OpenPKG Framework "bootstrap" package. + What you find here is rather complex and tricky stuff, so don't be + confused if you don't understand everything immediately. The Files --------- README .................. this file ;-) - HISTORY ................. change history tracking of this package openpkg.spec ............ the regular build procedure openpkg.boot ............ the bootstrapping procedure - gzip-*.tar .............. untouched distribution tarball of the GNU gzip tool - make-*.tar.gz ........... untouched distribution tarball of the GNU make tool patch-*.tar.gz .......... untouched distribution tarball of the GNU patch tool bash-*.tar.gz ........... untouched distribution tarball of the GNU bash tool + make-*.tar.gz ........... untouched distribution tarball of the GNU make tool tar-*.tar.gz ............ untouched distribution tarball of the GNU tar tool + config-*.tar.gz ......... untouched distribution tarball of the GNU config scripts + gzip-*.tar .............. pre-unpacked distribution tarball of the GNU gzip tool + gzip-*-openpkg-r*.tar ... pre-patched distribution files of the GNU gzip tool + perl-*-mini.tar.gz ...... stripped down distribution tarball of the Perl tool + rpm-*.tar.gz ............ untouched distribution tarball of the RPM tool + openssl-*.tar.gz ........ untouched distribution tarball of the OpenSSL toolkit uuid-*.tar.gz ........... untouched distribution tarball of the OSSP uuid tool curl-*.tar.gz ........... untouched distribution tarball of the cURL tool + beecrypt-*.tar.gz ....... untouched distribution tarball of the BeeCrypt library bzip2-*.tar.gz .......... untouched distribution tarball of the BZIP2 library zlib-*.tar.gz ........... untouched distribution tarball of the ZLIB library - beecrypt-*.tar.gz ....... untouched distribution tarball of the BeeCrypt library - rpm-*.tar.gz ............ untouched distribution tarball of the RPM tool - config-*.tar.gz ......... untouched distribution tarball of the GNU config scripts - openpkg-registry-*.tar.gz untouched distribution tarball of the OpenPKG Registry - openpkg-tools-*.tar.gz .. untouched distribution tarball of the OpenPKG Tool Chain - openssl-*.tar.gz ........ untouched distribution tarball of the OpenSSL toolkit - perl-*-mini.tar.gz ...... stripped down distribution tarball of the Perl tool + popt-*.tar.gz ........... untouched distribution tarball of the POPT library + sqlite-*.tar.gz ......... untouched distribution tarball of the SQLite library + pcre-*.tar.gz ........... untouched distribution tarball of the SQLite library + diffutils-*.tar.gz ...... untouched distribution tarball of the GNU diffutils toolkit + svs-*.tar.gz ............ untouched distribution tarball of the OSSP svs tool + xz-*.tar.gz ............. untouched distribution tarball of the XZ tool - make.patch .............. patch for GNU make - bash.patch .............. patch for GNU bash - tar.patch ............... patch for GNU tar - beecrypt.patch .......... patch for BeeCrypt - openssl.patch ........... patch for OpenSSL - perl.patch .............. patch for Perl - gzip.c .................. replacement file for GNU gzip - rpm.patch.bugfix ........ patch for RPM (bugfixing parts) - rpm.patch.feature ....... patch for RPM (new features parts) - rpm.patch.porting ....... patch for RPM (portability enhancement parts) - rpm.patch.regen ......... patch for RPM (re-generated files parts) + bash.patch .............. patch for GNU bash tool + bash.patch.vendor ....... patch for GNU bash tool (upstream vendor only) + bash.patch.vendor.sh .... patch for GNU bash tool (generation utility, NOT BUNDLED) + beecrypt.patch .......... patch for BeeCrypt library + make.patch .............. patch for GNU make tool + openssl.patch ........... patch for OpenSSL toolkit + perl.patch .............. patch for Perl tool + tar.patch ............... patch for GNU tar tool + rpm.patch ............... patch for RPM tool + popt.patch .............. patch for POPT library + sqlite.patch ............ patch for SQLite library + curl.patch .............. patch for cURL library + diffutils.patch ......... patch for GNU diffutils tool + libarchive.patch ........ patch for BSD libarchive tool + pcre.patch .............. patch for PCRE library + xz.patch ................ patch for XZ tool rpmpopt ................. replacements/extensions for RPM's POPT configuration rpmmacros ............... replacements/extensions for RPM's macros - rpmrc ................... replacements for RPM's run-command configuration root.README ............. the source for installed /README local.README ............ the source for installed /local/README @@ -55,6 +63,7 @@ dot.lsyncrc ............. the source for installed /local/.lsyncrc openpkg.c ............... the OpenPKG frontend (set-uid wrapper) + openpkg.mk .............. the OpenPKG frontend (build procedure) openpkg.sh .............. the OpenPKG frontend (main script) openpkg.pod ............. the OpenPKG frontend manual page (source) openpkg.1 ............... the OpenPKG frontend manual page (pre-generated output) @@ -89,31 +98,74 @@ lsync.8 ................. the lsync tool (manual page) lsync.pod ............... the lsync tool (manual page source) - aux.usrgrp.sh ........... user/group name/id determination script - aux.prereq.sh ........... prerequisite checking script - aux.wrapsrc.sh .......... wrapper script for generating openpkg-V-R.src.sh - aux.wrapbin.sh .......... wrapper script for generating openpkg-V-R.P-L.sh + etc.usrgrp.sh ........... user/group name/id determination script + etc.prereq.sh ........... prerequisite checking script + etc.wrapsrc.sh .......... wrapper script for generating openpkg-V-R.src.sh + etc.wrapbin.sh .......... wrapper script for generating openpkg-V-R.P-L.sh - pod2man.sh .............. helper script for pre-generating manual page outputs man.sh .................. helper script for "openpkg man" command - install.sh .............. helper script for "openpkg install" command + + rpm.sh .................. wrapper for RPM + curl.sh ................. wrapper for cURL + + dev.pl .................. the OpenPKG package development utility script + dev.pod ................. the OpenPKG package development utility manual page (source) + dev.8 ................... the OpenPKG package development utility manual page (pre-generated output) + + index.pl ................ the OpenPKG package indexing utility script + index.pod ............... the OpenPKG package indexing utility manual page (source) + index.8 ................. the OpenPKG package indexing utility manual page (pre-generated output) + + search.pl ............... the OpenPKG package searching utility script + search.pod .............. the OpenPKG package searching utility manual page (source) + search.8 ................ the OpenPKG package searching utility manual page (pre-generated output) + + sea.sh .................. the OpenPKG shell execution archive utility script + sea.pod ................. the OpenPKG shell execution archive utility manual page (source) + sea.8 ................... the OpenPKG shell execution archive utility manual page (pre-generated output) + + mirror.pl ............... the OpenPKG package mirroing utility script + mirror.pod .............. the OpenPKG package mirroing utility manual page (source) + mirror.8 ................ the OpenPKG package mirroing utility manual page (pre-generated output) + + build.pl ................ the OpenPKG package building utility script + build.pod ............... the OpenPKG package building utility manual page (source) + build.8 ................. the OpenPKG package building utility manual page (pre-generated output) + + makeproxy.pl ............ the OpenPKG proxy package building utility script + makeproxy.pod ........... the OpenPKG proxy package building utility manual page (source) + makeproxy.8 ............. the OpenPKG proxy package building utility manual page (pre-generated output) openpkg.org.pgp ......... the OpenPGP public key "OpenPKG " openpkg.com.pgp ......... the OpenPGP public key "OpenPKG GmbH " openpkg.net.pgp ......... the OpenPGP public key "OpenPKG Foundation e.V. " + license.sh .............. the OpenPKG license management utility script + license.pod ............. the OpenPKG license management utility manual page (source) + license.8 ............... the OpenPKG license management utility manual page (pre-generated output) + license-BOOT.txt ........ the OpenPKG Framework Bootstrapping License + license-COMMUNITY.txt ... the OpenPKG Framework Community License + license-EVAL.txt ........ the OpenPKG Framework Evaluation License + license-EXAMPLE.txt ..... the OpenPKG Framework Example License + license-PROMO.txt ....... the OpenPKG Framework Promotion License + license-RECOVERY.txt .... the OpenPKG Framework Recovery License + license.lua ............. the OpenPKG Framework license processor script + + Makefile ................ development build procedures + The Bootstrapping Procedure --------------------------- The complexity of this OpenPKG RPM package results from the fact that we force us to treat this bootstrapping package equal to every other regular OpenPKG RPM package. First, this implies that the packaging - tool RPM is packaged with itself as an OpenPKG RPM package (means: its - build procedure is a real RPM .spec file and it can be installed and - upgraded through a binary or source RPM). Second, RPM is installed - into the same filesystem hierarchy as all other packages. Third, RPM - manages its own files. The reason for this approach should be obvious: - 100% consistency for the whole OpenPKG software packaging facility! + tool RPM is packaged with itself as an OpenPKG RPM package -- which + means that its build procedure is a real RPM .spec file and it can be + installed and upgraded through a binary or source RPM. Second, RPM is + installed into the same filesystem hierarchy as all other packages. + Third, RPM manages its own files. The reason for this approach should + be obvious: 100% consistency for the whole OpenPKG software packaging + facility! The drawback is that this package requires a very tricky bootstrapping procedure which had cost a lot of time to figure out and establish. If @@ -137,17 +189,17 @@ scripts of "openpkg.spec", there is a fresh version of the target filesystem hierarchy staying under a temporary "build root". The "openpkg.boot" script then creates a very special temporary "openpkg - rpm" command which allows the installed "openpkg rpm" command inside - the "build root" to work (although it is built for the final target - filesystem path). Then the $RPM_BOOT variable is set and the package - is _again_ build via "openpkg.spec" -- but this time with the real - OpenPKG RPM. To avoid unneccessary re-compilation, the "openpkg.spec" - skips "%prep", "%build" and "%install" sections if $RPM_BOOT is - defined. So, on this second build phase, only the "%files" section is - executed, i.e., a binary OpenPKG RPM package "openpkg-V-R.P-T.rpm" - is rolled from the files in the "build root". Additionally, a source - OpenPKG RPM package "openpkg-V-R.src.rpm" is rolled for consistency - reasons. + rpm" command which allows the installed "openpkg rpm" command + inside the "build root" to work (although it is built for the + final target filesystem path). Then the $OPENPKG_BOOT variable + is set and the package is _again_ build via "openpkg.spec" -- + but this time with the real OpenPKG RPM. To avoid unneccessary + re-compilation, the "openpkg.spec" skips "%prep", "%build" and + "%install" sections if $OPENPKG_BOOT is defined. So, on this second + build phase, only the "%files" section is effectively executed, i.e., + a binary OpenPKG RPM package "openpkg-V-R.P-T.rpm" is rolled from the + files in the "build root". Additionally, a source OpenPKG RPM package + "openpkg-V-R.src.rpm" is rolled for consistency reasons, too. Finally, we override the installation in the "build root" again by installing the now rolled binary OpenPKG RPM package @@ -169,14 +221,14 @@ is packed into a "tarball", compressed, again wrapped into another tarball together with the uncompression tools ("bzip2" and "tar"), and finally wrapped into a self-extracting shell script by appending - "aux.wrapbin.sh" (padded to 64KB for easier unpacking of the attached + "etc.wrapbin.sh" (padded to 64KB for easier unpacking of the attached tarball) to its front. The result is the binary bootstrap script "openpkg-V-R.P-T.sh" which - can be used to install the target hierarchy from scratch without any - pre-installed OpenPKG RPM. Nevetheless, the installed target hierarchy - looks _exactly_ as it would have been installed with OpenPKG RPM. - If one later wants to upgrade this hierarchy one can just use the + can be used to install the target hierarchy from scratch without + any pre-installed OpenPKG RPM. Nevertheless, the installed target + hierarchy looks _exactly_ as it would have been installed with OpenPKG + RPM. If one later wants to upgrade this hierarchy one can just use the generated (or a newer) "openpkg-V-R.P-T.rpm". To allow one to easily repeat this from-source bootstrapping procedure