From 7a2f61aa073a8414791bd26dff1dcfabacf1011e Mon Sep 17 00:00:00 2001 From: cyeoh <> Date: Sep 28 2000 10:33:22 +0000 Subject: Initial checkin of packaging config files --- diff --git a/lsb_release/README b/lsb_release/README new file mode 100644 index 0000000..0143f57 --- /dev/null +++ b/lsb_release/README @@ -0,0 +1,59 @@ +This directory contains: + +src - directory containing the source for lsb_release +lsb_release.spec - the spec file for generating RPM packages for lsb_release +debian - directory containing the necessary configuration files for + generating a deb packages for lsb_release + + +Generating a release +-------------------- + +1. Checkout a snapshot + +cvs -d :pserver:anonymous@cvs.lsb.sourceforge.net:/cvsroot/lsb export lsb_release + +2. Choose a version number (example commands following will assume +1.1) and rename the src directory appropriately. + +cd lsb_release +mv src lsb-release-1.1 + +3a. Create the tarball release + +tar cvfz lsb-release-1.1.tar.gz lsb-release-1.1 + +3b. Create the rpm release + +i. Create a tarball + +tar cvfz lsb-release-1.1.tgz lsb-release-1.1 + +ii. Modify the spec file appropriately (if the version number has +changed, change the Version and Source fields). These changes should +later be checked into CVS. + +iii. Build the source and binary RPM package (exact details may vary +if not building on a Red Hat system) + +cp lsb_release.spec /usr/src/redhat/SPECS +mv lsb-release-1.1.tgz /usr/src/redhat/SOURCES +rpm -ba /usr/src/redhat/SPECS/lsb_release.spec + +This should result in the following files being generated: + +/usr/src/redhat/RPMS/noarch/lsb-release-1.1-1.noarch.rpm +/usr/src/redhat/SRPMS/lsb-release-1.1-1.src.rpm + +3c. Create the deb package release + +i. Move the debian directory into the renamed src directory + +mv debian lsb-release-1.1 + +ii. Build the debian packages + +cd lsb-release-1.1 +dpkg-buildpackage -rfakeroot + +4. Upload the various release files to the Source Forge site. diff --git a/lsb_release/debian/README.Debian b/lsb_release/debian/README.Debian new file mode 100644 index 0000000..c217efc --- /dev/null +++ b/lsb_release/debian/README.Debian @@ -0,0 +1,7 @@ +lsb-release for Debian +---------------------- + +This version of lsb-release may not work with versions +of sh that are not fully posix compliant. + + -- Christopher Yeoh , Wed, 27 Sep 2000 12:07:55 +1100 diff --git a/lsb_release/debian/changelog b/lsb_release/debian/changelog new file mode 100644 index 0000000..bf1bb20 --- /dev/null +++ b/lsb_release/debian/changelog @@ -0,0 +1,9 @@ +lsb-release (1.0-1) unstable; urgency=low + + * Initial Release. + + -- Christopher Yeoh Wed, 27 Sep 2000 12:07:55 +1100 + +Local variables: +mode: debian-changelog +End: diff --git a/lsb_release/debian/control b/lsb_release/debian/control new file mode 100644 index 0000000..081d03d --- /dev/null +++ b/lsb_release/debian/control @@ -0,0 +1,19 @@ +Source: lsb-release +Section: contrib/base +Priority: optional +Maintainer: Christopher Yeoh +Standards-Version: 3.1.1 + +Package: lsb-release +Architecture: all +Depends: +Description: LSB version query program + This program forms part of the required functionality of + the LSB (Linux Standard Base) specification. + . + The program queries the installed state of the distribution + to display certain properties such as the version of the + LSB against which the distribution claims compliance as + well. It can also attempt to display the name and release + of the distribution along with an identifier of who produces + the distribution. diff --git a/lsb_release/debian/copyright b/lsb_release/debian/copyright new file mode 100644 index 0000000..b5653f4 --- /dev/null +++ b/lsb_release/debian/copyright @@ -0,0 +1,25 @@ +This package was debianized by Christopher Yeoh on +Wed, 27 Sep 2000 12:07:55 +1100. + +It was downloaded from http://lsb.sourceforge.net + +Upstream Author(s): Dominique MASSONIE + +Copyright: + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; version 2 dated June, 1991. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + +On Debian GNU systems, the complete text of the GNU General +Public License can be found in `/usr/share/common-licenses/GPL'. + diff --git a/lsb_release/debian/docs b/lsb_release/debian/docs new file mode 100644 index 0000000..e845566 --- /dev/null +++ b/lsb_release/debian/docs @@ -0,0 +1 @@ +README diff --git a/lsb_release/debian/postinst.debhelper b/lsb_release/debian/postinst.debhelper new file mode 100644 index 0000000..160d447 --- /dev/null +++ b/lsb_release/debian/postinst.debhelper @@ -0,0 +1,7 @@ +# Automatically added by dh_installdocs +if [ "$1" = "configure" ]; then + if [ -d /usr/doc -a ! -e /usr/doc/lsb-release -a -d /usr/share/doc/lsb-release ]; then + ln -sf ../share/doc/lsb-release /usr/doc/lsb-release + fi +fi +# End automatically added section diff --git a/lsb_release/debian/prerm.debhelper b/lsb_release/debian/prerm.debhelper new file mode 100644 index 0000000..bc9deac --- /dev/null +++ b/lsb_release/debian/prerm.debhelper @@ -0,0 +1,5 @@ +# Automatically added by dh_installdocs +if [ \( "$1" = "upgrade" -o "$1" = "remove" \) -a -L /usr/doc/lsb-release ]; then + rm -f /usr/doc/lsb-release +fi +# End automatically added section diff --git a/lsb_release/debian/rules b/lsb_release/debian/rules new file mode 100755 index 0000000..0ecd4b7 --- /dev/null +++ b/lsb_release/debian/rules @@ -0,0 +1,64 @@ +#!/usr/bin/make -f +# Sample debian/rules that uses debhelper. +# GNU copyright 1997 to 1999 by Joey Hess. + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +# This is the debhelper compatability version to use. +export DH_COMPAT=1 + +build: build-stamp +build-stamp: + dh_testdir + # Make the documentation + $(MAKE) + + touch build-stamp + +clean: + dh_testdir + dh_testroot + rm -f build-stamp configure-stamp + rm -f lsb_release.1.bz2 + # Add here commands to clean up after the build process. + dh_clean + +install: build + dh_testdir + dh_testroot + dh_clean -k + dh_installdirs + + # Add here commands to install the package into debian/tmp. + $(MAKE) install prefix=`pwd`/debian/tmp/opt/lsb + + # Debian man doesn't understand bzip2'd man pages so we'll + # convert it to a gzipped man page + bzip2 -d -c debian/tmp/opt/lsb/man/man1/lsb_release.1.bz2 | gzip > debian/tmp/opt/lsb/man/man1/lsb_release.1.gz + +# Build architecture-independent files here. +binary-indep: build install +# dh_testversion + dh_testdir + dh_testroot + dh_installdocs + dh_installmanpages + dh_installchangelogs + dh_link opt/lsb/bin/lsb_release opt/bin/lsb_release + dh_link opt/lsb/man/man1/lsb_release.1.gz opt/man/man1/lsb_release.1.gz + dh_compress + dh_fixperms + # You may want to make some executables suid here. + dh_installdeb + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +# Build architecture-dependent files here. +binary-arch: build install +# We have nothing to do here. + +binary: binary-indep binary-arch +.PHONY: build clean binary-indep binary-arch binary install diff --git a/lsb_release/lsb_release.spec b/lsb_release/lsb_release.spec new file mode 100644 index 0000000..bfc7787 --- /dev/null +++ b/lsb_release/lsb_release.spec @@ -0,0 +1,60 @@ +# +# Copyright 1999, International Business Machines, Inc. +# George Kraft IV (gk4@us.ibm.com) +# +# Red Hat Package Manager (RPM) file for LSB +# +Summary: Linux Standard Base tools +Name: lsb_release +Version: 1.1 +Release: 1 +Prefix: /opt +Copyright: GPL +Source: lsb_release-1.0.tgz +Group: System/Tools +URL: http://www.linuxbase.org/ +Vendor: Linux Standard Base +Packager: George Kraft IV +BuildArchitectures: noarch +BuildRoot: /var/tmp/%{name}-root + +%description +Linux Standard Base (LSB) tools. + +%prep + +%setup + +%build +rm -rf $RPM_BUILD_ROOT +make + +%install +make prefix=${RPM_BUILD_ROOT}%{prefix}/lsb install + +%clean +rm -rf $RPM_BUILD_ROOT + +%files +%{prefix}/lsb/bin/lsb_release +%{prefix}/lsb/man/man1/lsb_release.1.gz + +%post +P=$RPM_INSTALL_PREFIX +mkdir -p $P/bin/ > /dev/null 2>&1 +ln -fs $P/lsb/bin/lsb_release $P/bin/ +mkdir -p $P/man/man1/ > /dev/null 2>&1 +ln -fs $P/lsb/man/man1/lsb_release.1.gz $P/man/man1/ + +%postun +rm -f $RPM_INSTALL_PREFIX/bin/lsb_release +rm -f $RPM_INSTALL_PREFIX/man/man1/lsb_release/lsb_release.1.gz + +%changelog +* Thu Sep 28 2000 Christopher Yeoh +- Changes for 1.1 release of lsb_release + +* Tue Sep 26 2000 Christopher Yeoh +- Clean up script not to trample over currently installed package +- Changes to use new makefile bundled with lsb_release tarball +- Fixes bugs in post commands and adds post uninstall commands diff --git a/lsb_release/src/Makefile b/lsb_release/src/Makefile new file mode 100644 index 0000000..bd699a5 --- /dev/null +++ b/lsb_release/src/Makefile @@ -0,0 +1,22 @@ +# +# Makefile for lsb_release program +# + +# Config +prefix=/opt/lsb + +all: man + +man: lsb_release.1.gz + +lsb_release.1.gz: lsb_release + @cp -p lsb_release lsb_release.orig + @cat lsb_release.orig | sed -e "s/\[ -n \"\$ARG_V\" \] \&\& DisplayVersion/\[ -n \"\$ARG_V\" \] \&\& Version/" >./lsb_release + @chmod a+x ./lsb_release + @./help2man -N --include ./lsb_release.examples ./lsb_release >lsb_release.1 + @mv lsb_release.orig lsb_release + @gzip -f lsb_release.1 + +install: all + install -D -m 644 lsb_release.1.gz ${prefix}/man/man1/lsb_release.1.gz + install -D -m 755 lsb_release ${prefix}/bin/lsb_release