Hello again,
thanks to all who replied to my previous mail. Using your advice I
solved/correct all the problems/bugs, but still there is one thing I
don't understand:
Lionel Elie Mamane wrote:
On Wed, Aug 03, 2005 at 11:21:35AM +0200, Tomas Davidek wrote:
* I store all the scripts in a tarball,
If you are using the .orig.tar.gz directly, you have misunderstood the
structure of a Debian source package: The .orig.tar.gz is unpacked,
the tree is patched with the .diff.gz and then one builds / installs
entirely from there.
You may actually want to do a "Debian native" package that has only a
.tar.gz and no .diff.gz.
Yes, this is exactly the problem - the *.orig.tar.gz should be unpacked,
but apparently it is not. When I have in my makefile:
.....
install:
cp -a usr $(DESTDIR)/usr
.....
it fails with the error message:
--------------
# Add here commands to install the package into debian/ucjf-security.
/usr/bin/make install
DESTDIR=/home/davidek/debian/ucjf-security-1.0.2/debian/ucjf-security
make[1]: Entering directory `/home/davidek/debian/ucjf-security-1.0.2'
cp -a usr /home/davidek/debian/ucjf-security-1.0.2/debian/ucjf-security/usr
cp: cannot stat `usr': No such file or directory
make[1]: *** [install] Error 1
make[1]: Leaving directory `/home/davidek/debian/ucjf-security-1.0.2'
make: *** [install] Error 2
---------
Someone of you mentioned that it should be debian/rules script that
unpacks the .orig.tar.gz. I tried to issue the commands one-by-one, but
none of them unpacked the orig tarball. BTW, should it be unpacked into
/home/davidek/debian/ucjf-security-1.0.2 (see above) or somewhere else ?
I probably miss something in the debian/rules (attached), the full
output of dpkg-buildpackage -rfakeroot is also attached.
Thanks a lot for help,
best regards
Tomas
E-mail : [EMAIL PROTECTED],
[EMAIL PROTECTED]
dpkg-buildpackage: source package is ucjf-security
dpkg-buildpackage: source version is 1.0.2-1
dpkg-buildpackage: source maintainer is Tomas Davidek <[EMAIL PROTECTED]>
dpkg-buildpackage: host architecture is i386
fakeroot debian/rules clean
dh_testdir
dh_testroot
rm -f build-stamp configure-stamp
# Add here commands to clean up after the build process.
#-/usr/bin/make clean
dh_clean
rm -f debian/ucjf-security.substvars
rm -f debian/ucjf-security.*.debhelper
rm -rf debian/ucjf-security
rm -f debian/files
find . -type f -a \( -name \#\*\# -o -name .\*\~ -o -name \*\~ -o -name
DEADJOE -o -name \*.orig -o -name \*.rej -o -name \*.bak -o -name .\*.orig -o
-name .\*.rej -o -name .SUMS -o -name TAGS -o -name core -o \( -path
\*/.deps/\* -a -name \*.P \) \) -exec rm -f {} \;
rm -rf autom4te.cache
dpkg-source -b ucjf-security-1.0.2
dpkg-source: building ucjf-security using existing
ucjf-security_1.0.2.orig.tar.gz
dpkg-source: building ucjf-security in ucjf-security_1.0.2-1.diff.gz
dpkg-source: warning: ignoring deletion of directory sbin
dpkg-source: warning: ignoring deletion of file sbin/hledej_skodice
dpkg-source: warning: ignoring deletion of file sbin/ipt-skodici
dpkg-source: building ucjf-security in ucjf-security_1.0.2-1.dsc
debian/rules build
dh_testdir
# Add here commands to configure the package.
touch configure-stamp
dh_testdir
# Add here commands to compile the package.
#/usr/bin/make
#docbook-to-man debian/ucjf-security.sgml > ucjf-security.1
touch build-stamp
fakeroot debian/rules binary
dh_testdir
dh_testroot
dh_clean -k
rm -f debian/ucjf-security.substvars
rm -f debian/ucjf-security.*.debhelper
rm -rf debian/ucjf-security
find . -type f -a \( -name \#\*\# -o -name .\*\~ -o -name \*\~ -o -name
DEADJOE -o -name \*.orig -o -name \*.rej -o -name \*.bak -o -name .\*.orig -o
-name .\*.rej -o -name .SUMS -o -name TAGS -o -name core -o \( -path
\*/.deps/\* -a -name \*.P \) \) -exec rm -f {} \;
rm -rf autom4te.cache
dh_installdirs
install -d debian/ucjf-security
install -d debian/ucjf-security/usr/sbin
# Add here commands to install the package into debian/ucjf-security.
/usr/bin/make install
DESTDIR=/home/davidek/debian/ucjf-security-1.0.2/debian/ucjf-security
make[1]: Entering directory `/home/davidek/debian/ucjf-security-1.0.2'
cp -a usr /home/davidek/debian/ucjf-security-1.0.2/debian/ucjf-security/usr
cp: cannot stat `usr': No such file or directory
make[1]: *** [install] Error 1
make[1]: Leaving directory `/home/davidek/debian/ucjf-security-1.0.2'
make: *** [install] Error 2
#!/usr/bin/make -f
# -*- makefile -*-
# Sample debian/rules that uses debhelper.
# This file was originally written by Joey Hess and Craig Small.
# As a special exception, when this file is copied by dh-make into a
# dh-make output file, you may use that output file without restriction.
# This special exception was added by Craig Small in version 0.37 of dh-make.
# Uncomment this to turn on verbose mode.
export DH_VERBOSE=1
CFLAGS = -Wall -g
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
else
CFLAGS += -O2
endif
configure: configure-stamp
configure-stamp:
dh_testdir
# Add here commands to configure the package.
touch configure-stamp
build: build-stamp
build-stamp: configure-stamp
dh_testdir
# Add here commands to compile the package.
#$(MAKE)
#docbook-to-man debian/ucjf-security.sgml > ucjf-security.1
touch build-stamp
clean:
dh_testdir
dh_testroot
rm -f build-stamp configure-stamp
# Add here commands to clean up after the build process.
#-$(MAKE) clean
dh_clean
install: build
dh_testdir
dh_testroot
dh_clean -k
dh_installdirs
# Add here commands to install the package into debian/ucjf-security.
$(MAKE) install DESTDIR=$(CURDIR)/debian/ucjf-security
# Build architecture-independent files here. Everything here, since we have
# just set of scripts:
binary-indep: build install
dh_testdir
dh_testroot
dh_installchangelogs
dh_installdocs README TODO
dh_installexamples
# dh_install
# dh_installmenu
# dh_installdebconf
# dh_installlogrotate
# dh_installemacsen
# dh_installpam
# dh_installmime
# The following command installs config file ucjf-security into
# /etc/default/ucjf-security and the initscript ucjf-security.init into
# /etc/init.d/ucjf-security
dh_installinit
#
# Here, I want to install ucjf-security.cron.daily into /etc/cron.daily:
dh_installcron
#
# dh_installinfo
dh_installman hledej_skodice.8 ipt-skodici.8
dh_link
dh_strip
dh_compress
dh_fixperms
# dh_perl
# dh_python
# dh_makeshlibs
dh_installdeb
dh_shlibdeps
dh_gencontrol
dh_md5sums
dh_builddeb
# Build architecture-dependent files here.
binary-arch: build install
# We have nothing to do by default.
binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install configure