Debian/Ubuntu Packaging Nightmares
Jon <[email protected]>
| Newsgroups | gmane.user-groups.linux.ottawa.general |
|---|---|
| Message-ID | <[email protected]> |
Tearing my hair out trying to make a debian package (for ubuntu 10.04).
The long and short of it is, I'm trying to package the latest gsoap
(v2.7.17 - the package with ubuntu is an ancient v2.7.9) as it's what
we're using.
My feeble attempts at making both gsoap and gsoap-dev packages have all
resulted in failure.
My control file:
-----------------------------------------------------------
Source: gsoap
Priority: optional
Maintainer: xxx
Build-Depends: dpatch, debhelper (>= 7), autotools-dev
Standards-Version: 3.8.3
Section: libs
Homepage: http://gsoap2.sourceforge.net
Package: gsoap-dev
Section: libdevel
Architecture: any
Depends: gsoap (= ${binary:Version})
Description: gSoap development libraries, header files and documentation.
Contains the headers and libraries for gsoap.
Package: gsoap
Section: libs
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: SOAP stub and skeleton compiler for C and C++
The gSOAP toolkit provides a unique SOAP-to-C/C++ language
binding for the development of SOAP Web Services and clients.
-----------------------------------------------------------
My rules file:
-----------------------------------------------------------
export DH_VERBOSE=1
DEB_CONFIGURE_PREFIX = /usr
DEB_CONFIGURE_EXTRA_FLAGS = --disable-static
%:
dh $@
patch:
dpatch apply-all
autoreconf --install --force
unpatch:
dpatch deapply-all
build: patch
make
install: build
dh_install --sourcedir=debian/tmp
binary: build install
clean: unpatch
-make clean
-----------------------------------------------------------
I've noticed the VERBOSE flag doesn't seem to do much. The line for
dh_install I found in the dh_install script, but it doesn't seem to have
helped much. Aside that, the source is patched properly, the configure
command is somehow run with the right options (I don't profess to fully
understand the mechanics behind the configure/make process even after a
few years of simply using it). Looks like a make command somehow kicks
off a status check which then runs configure.... Anyway, the output:
-----------------------------------------------------------
> fakeroot debian/rules build
dpatch apply-all
autoreconf --install --force
libtoolize: putting auxiliary files in `.'.
libtoolize: copying file `./config.guess'
libtoolize: copying file `./config.sub'
libtoolize: copying file `./install-sh'
libtoolize: copying file `./ltmain.sh'
libtoolize: Consider adding `AC_CONFIG_MACRO_DIR([m4])' to configure.in and
libtoolize: rerunning libtoolize, to keep the correct libtool macros
in-tree.
libtoolize: Consider adding `-I m4' to ACLOCAL_AMFLAGS in Makefile.am.
libtoolize: `AC_PROG_RANLIB' is rendered obsolete by `LT_INIT'
make
make[1]: Entering directory `/usr/local/src/gsoap-2.7.17'
/bin/bash ./config.status --recheck
running CONFIG_SHELL=/bin/bash /bin/bash ./configure
--build=i486-linux-gnu --prefix=/usr --includedir=${prefix}/include
--mandir=${prefix}/share/man --infodir=${prefix}/share/info
--sysconfdir=/etc --localstatedir=/var --libexecdir=${prefix}/lib/gsoap
--disable-maintainer-mode --disable-dependency-tracking
build_alias=i486-linux-gnu --no-create --no-recursion
configure: WARNING: unrecognized options: --disable-maintainer-mode
...
checking for disable openssl in library... no
configure: creating ./config.status
configure: WARNING: unrecognized options: --disable-maintainer-mode
/bin/bash ./config.status
config.status: creating Makefile
...
>
-----------------------------------------------------------
Looks like it built okay. Now, when I run the command with the binary
target, it runs through the whole patch/configure/make process again
(why?). This time, the install target gets run but it croaks with:
-----------------------------------------------------------
dh_install --sourcedir=debian/tmp
cp -a debian/tmp/usr/include/stdsoap2.h debian/gsoap-dev//usr/include/
dh_install: gsoap-dev missing files (usr/lib/lib*.a), aborting
make: *** [install] Error 255
-----------------------------------------------------------
I cannot for the lift of me see what I'm doing wrong - all the guides
I've read seem to suggest doing exactly what I'm doing so either they're
wrong or (more likely) I've misinterpreted or misunderstood something
(but.. what?)
After two days of pulling out my hair (which is quite the feat when
there's none to pull), I'm thinking I'll simplify - scrap the dream of
making both packages and just stuff it all into one big package.
Can anyone help me to write a debian/rules file that will:
1. Patch some files, including some Makefile.am files?
2. Run:
autoreconf --install --force
3. Run a custom configure command:
./configure --disable-static --prefix=/usr
4. Build (and clean) the project.
5. Most important: Generate the deb file.
I've googled for "simple guides", ala Making Debian Packages for Dummies
to making not-so-simple deb packages (ie: those which contain a couple
of binaries, some shared libs, some headers, etc.) and have found nothing.
I really need to sort this out as there are other software kits we're
I'll need to make into packages as well.
--
OCLUG general discussion list
[email protected]
http://oclug.on.ca/mailman/listinfo/oclug