On Friday 29 January 2010 08.42:21 Martin Sustrik wrote: > Hi Adrian, Peter, Mato, > > According to you suggestions I moved packages/debian directory to > project root. > > Adrian, please let me know what should be imported to the directory to > make it up-to-date with current Debian package.
Below. * Note that it's packaging 2.0beta2 and not git head. Packaging will always lag behind, since I'm planning to work off tarballs and not follow git. (Although as long as I keep packaging beta tarballs the final diff between what's delivered in the tarball and what gets uploaded to Debian should be quite small.) * Diff is quite big since I started unaware of Peter's work and just imported some bits and took ideas. * [binary] Package name is libzmq0 instead of libzeromq0, because it's strongly reccommended to have soname and package name match. * The biggest regression is of course loss of cl packaging. OTOH cl bindings are not in git anymore, so no reason to still carry the packaging... Ruby/Python packages that were generated by Peter's packaging were only placeholders in any case. cheers -- vbi -- Today is Prickle-Prickle, the 29th day of Chaos in the YOLD 3176
From 38a08a78222e3375e01b8aed6a94c241d167f4a4 Mon Sep 17 00:00:00 2001 From: Adrian von Bidder <[email protected]> Date: Fri, 29 Jan 2010 11:20:01 +0100 Subject: [PATCH] Packaging of 2.0beta2 tarball. Signed-off-by: Adrian von Bidder <[email protected]> --- debian/README.Debian | 10 +-- debian/README.source | 37 ++++++++ debian/TODO.source | 15 +++ debian/changelog | 7 +- debian/cl-zeromq.files | 7 -- debian/cl-zeromq.install | 6 -- debian/cl-zeromq.links | 1 - debian/control | 138 +++++++----------------------- debian/copyright | 103 ++++++++++++++++++++-- debian/dirs | 5 - debian/docs | 2 - debian/hgpkg | 182 +++++++++++++++++++++++++++++++++++++++ debian/libzeromq-dev.files | 37 -------- debian/libzeromq-dev.install | 19 ---- debian/libzeromq-python.files | 1 - debian/libzeromq-python.install | 1 - debian/libzeromq-ruby.files | 1 - debian/libzeromq-ruby.install | 1 - debian/libzeromq0.files | 2 - debian/libzeromq0.install | 1 - debian/libzmq-dev.install | 5 + debian/libzmq-dev.manpages | 2 + debian/libzmq0.install | 1 + debian/libzmq0.manpages | 6 ++ debian/rules | 121 ++++++++------------------ debian/shlibs.local | 1 - debian/source/format | 1 + debian/source/options | 1 + debian/zeromq-examples.files | 2 - debian/zeromq-examples.install | 2 - debian/zeromq-perf.files | 10 -- debian/zeromq-perf.install | 10 -- debian/zeromq-utils.files | 6 -- debian/zeromq-utils.install | 9 +-- debian/zeromq-utils.manpages | 3 + 35 files changed, 424 insertions(+), 332 deletions(-) create mode 100644 debian/README.source create mode 100644 debian/TODO.source delete mode 100644 debian/cl-zeromq.files delete mode 100644 debian/cl-zeromq.install delete mode 100644 debian/cl-zeromq.links delete mode 100644 debian/dirs delete mode 100644 debian/docs create mode 100755 debian/hgpkg delete mode 100644 debian/libzeromq-dev.files delete mode 100644 debian/libzeromq-dev.install delete mode 100644 debian/libzeromq-python.files delete mode 100644 debian/libzeromq-python.install delete mode 100644 debian/libzeromq-ruby.files delete mode 100644 debian/libzeromq-ruby.install delete mode 100644 debian/libzeromq0.files delete mode 100644 debian/libzeromq0.install create mode 100644 debian/libzmq-dev.install create mode 100644 debian/libzmq-dev.manpages create mode 100644 debian/libzmq0.install create mode 100644 debian/libzmq0.manpages delete mode 100644 debian/shlibs.local create mode 100644 debian/source/format create mode 100644 debian/source/options delete mode 100644 debian/zeromq-examples.files delete mode 100644 debian/zeromq-examples.install delete mode 100644 debian/zeromq-perf.files delete mode 100644 debian/zeromq-perf.install delete mode 100644 debian/zeromq-utils.files create mode 100644 debian/zeromq-utils.manpages diff --git a/debian/README.Debian b/debian/README.Debian index 4f447cc..cbbd2aa 100644 --- a/debian/README.Debian +++ b/debian/README.Debian @@ -1,6 +1,4 @@ -zeromq for Debian ------------------ - -<possible notes regarding this package - if none, delete this file> - - -- Peter Busser <[email protected]> Tue, 15 Dec 2009 16:11:38 +0100 +Currently, the zeromq Debian packages provide only the C and C++ +language API. The other language bindings are work in progress and will +become available as time permits; help welcome (just email me at [email protected].) diff --git a/debian/README.source b/debian/README.source new file mode 100644 index 0000000..c0c7266 --- /dev/null +++ b/debian/README.source @@ -0,0 +1,37 @@ +The source of this package is managed by using a hgpkg managed +mercurial repository at https://fortytwo.ch/hg/pkg-zeromq. (hgpkg is +currently included in the debian/ directoriy here and not separately packaged, +since it's not widely used yet.) + +Typically, you'd start by: + + $ wget TODO get upstream tarball + $ hg clone https://fortytwo.ch/hg/pkg-zeromq zeromq + $ debian/hgpkg build + +Description: the repository contains an "upstream" and a "default" branch; +"upstream" is directly imported from upstream's svn, and the default branch +contains the directory as it is to be packed by dpkg-source. + +So far, the upstream source is unpatched. + +Upstream is at: + http://www.zeromq.org/ + +Import a new upstream version: + + $ debian/hgpkg import <path/to/tar> + (<path/to/tar> is the upstream tarball to be imported; the upstream + version is extracted from the tarball filename. The import will switch to + the upstream branch, import, and switch back, and leave the uncommitted + merge on the default branch.) + -> now examine the merge, correct packaging issues, edit debian/changelog if + necessary. + $ hg ci -m "new package version" + $ debian/hgpkg build + -> if the package is good: + $ debian/hgpkg markdeb + +(arguably a mercurial bug: you'll get a merge conflict in .hgtags during +upstream import which you'll have to correct manually.) + diff --git a/debian/TODO.source b/debian/TODO.source new file mode 100644 index 0000000..519f811 --- /dev/null +++ b/debian/TODO.source @@ -0,0 +1,15 @@ +* use external openpgm instead of included one + -> openpgm doesn't include obvious build instruction and I don't really know + scons or cmake. Postponed for now. +* use external XmlParser instead of included one + -> Not sure, only makes sense if it is used somewhere else. +* ship example code in -dev packages +* include perf tests with -utils package + (or: check if they build/work correctly. See email from Martin Sustrik + <[email protected]>, <[email protected]>) +* TODO items in debian/rules + +# Later: +* non-C/C++ language bindings + -> possibly use separate source packages in preparation of upstream spin-off +* package cl-iolib (mail from Peter) diff --git a/debian/changelog b/debian/changelog index 5c6f2c5..44200f2 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,6 +1,5 @@ -zeromq (1.9-1m) unstable; urgency=low +zeromq (2.0~beta2-1) unstable; urgency=low - * Initial release. - - -- Peter Busser <[email protected]> Tue, 15 Dec 2009 16:11:38 +0100 + * Initial package (closes: #566125) + -- Adrian von Bidder <[email protected]> Tue, 26 Jan 2010 19:03:39 +0100 diff --git a/debian/cl-zeromq.files b/debian/cl-zeromq.files deleted file mode 100644 index 0f94c78..0000000 --- a/debian/cl-zeromq.files +++ /dev/null @@ -1,7 +0,0 @@ -usr/share/common-lisp/source/meta.lisp -usr/share/common-lisp/source/package.lisp -usr/share/common-lisp/source/zeromq-api.lisp -usr/share/common-lisp/source/zeromq.asd -usr/share/common-lisp/source/zeromq.lisp -usr/share/common-lisp/systems/zeromq.asd -usr/share/man/man7/zmq_cl.7 diff --git a/debian/cl-zeromq.install b/debian/cl-zeromq.install deleted file mode 100644 index 636e923..0000000 --- a/debian/cl-zeromq.install +++ /dev/null @@ -1,6 +0,0 @@ -bindings/cl/meta.lisp usr/share/common-lisp/source/ -bindings/cl/package.lisp usr/share/common-lisp/source/ -bindings/cl/zeromq-api.lisp usr/share/common-lisp/source/ -bindings/cl/zeromq.asd usr/share/common-lisp/source/ -bindings/cl/zeromq.lisp usr/share/common-lisp/source/ -usr/share/man/man7/zmq_cl.7 usr/share/man/man7/ diff --git a/debian/cl-zeromq.links b/debian/cl-zeromq.links deleted file mode 100644 index b3e79ff..0000000 --- a/debian/cl-zeromq.links +++ /dev/null @@ -1 +0,0 @@ -usr/share/common-lisp/source/zeromq.asd usr/share/common-lisp/systems/zeromq.asd diff --git a/debian/control b/debian/control index 916a675..cd167fe 100644 --- a/debian/control +++ b/debian/control @@ -1,43 +1,26 @@ Source: zeromq -Priority: extra -Maintainer: Peter Busser <[email protected]> -Build-Depends: debhelper (>= 7), uuid-dev, autoconf, pkg-config, automake, libtool, libglib2.0-dev, python-all-dev, python-dev, python-central -Standards-Version: 3.7.3 Section: libs +Priority: optional +Maintainer: Adrian von Bidder <[email protected]> +Build-Depends: debhelper (>= 7), libglib2.0-dev, python, uuid-dev +Standards-Version: 3.8.3 Homepage: http://www.zeromq.org/ -Vcs-Git: git://githumb.com/sustrik/zeromq2.git +Vcs-Browser: https://fortytwo.ch/hg/pkg-zeromq +Vcs-Hg: https://fortytwo.ch/hg/pkg-zeromq -Package: libzeromq-dev -Section: libdevel +Package: libzmq0 Architecture: any -Depends: libzeromq0 (= ${binary:Version}) -Description: Development files and static library for the ZeroMQ library - ZeroMQ is a very fast, thin messaging implementation which supports different - messaging models. It reaches 13.4 microseconds end-to-end latencies and up to - 4,100,000 messages a second today. It requires only a couple of pages in - resident memory. It supports different wire protocols: TCP, PGM, AMQP, and - SCTP. - . - There are C, C++, Lisp, Java, Python, Ruby, and .NET language APis. - . - It is fully distributed: no central servers to crash, millions of WAN and - LAN nodes. It is an extensible framework: kernel-style drivers for custom - hardware, protocols, or applications. - . - This package contains ZeroMQ related development libraries and header files. - -Package: libzeromq0 Section: libs -Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends} +Recommends: zeromq-utils Description: The ZeroMQ library ZeroMQ is a very fast, thin messaging implementation which supports different messaging models. It reaches 13.4 microseconds end-to-end latencies and up to - 4,100,000 messages a second today. It requires only a couple of pages in - resident memory. It supports different wire protocols: TCP, PGM, AMQP, and + 4,100,000 messages a second today, requires only a couple of pages in + resident memory and supports different wire protocols: TCP, PGM, AMQP, and SCTP. . - There are C, C++, Lisp, Java, Python, Ruby, and .NET language APis. + There are C, C++, Lisp, Java, Python, Ruby, and .NET language APIs. . It is fully distributed: no central servers to crash, millions of WAN and LAN nodes. It is an extensible framework: kernel-style drivers for custom @@ -45,37 +28,18 @@ Description: The ZeroMQ library . This package contains the ZeroMQ shared library. -Package: cl-zeromq -Section: devel -Architecture: all -Depends: libzeromq0 (= ${binary:Version}), common-lisp-controller, cl-cffi, cl-trivial-garbage, cl-iolib -Description: Common Lisp bindings for the ZeroMQ messaging library - ZeroMQ is a very fast, thin messaging implementation which supports different - messaging models. It reaches 13.4 microseconds end-to-end latencies and up to - 4,100,000 messages a second today. It requires only a couple of pages in - resident memory. It supports different wire protocols: TCP, PGM, AMQP, and - SCTP. - . - There are C, C++, Lisp, Java, Python, Ruby, and .NET language APis. - . - It is fully distributed: no central servers to crash, millions of WAN and - LAN nodes. It is an extensible framework: kernel-style drivers for custom - hardware, protocols, or applications. - . - This package contains the ZeroMQ Common Lisp bindings. - Package: zeromq-utils -Section: utils Architecture: any +Section: utils Depends: ${shlibs:Depends}, ${misc:Depends} Description: Utilities for ZeroMQ ZeroMQ is a very fast, thin messaging implementation which supports different messaging models. It reaches 13.4 microseconds end-to-end latencies and up to - 4,100,000 messages a second today. It requires only a couple of pages in - resident memory. It supports different wire protocols: TCP, PGM, AMQP, and + 4,100,000 messages a second today, requires only a couple of pages in + resident memory and supports different wire protocols: TCP, PGM, AMQP, and SCTP. . - There are C, C++, Lisp, Java, Python, Ruby, and .NET language APis. + There are C, C++, Lisp, Java, Python, Ruby, and .NET language APIs. . It is fully distributed: no central servers to crash, millions of WAN and LAN nodes. It is an extensible framework: kernel-style drivers for custom @@ -83,79 +47,41 @@ Description: Utilities for ZeroMQ . This package contains a few ZeroMQ related utilities. -Package: libzeromq-ruby -Section: ruby -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: Ruby language bindings for the ZeroMQ messaging library - ZeroMQ is a very fast, thin messaging implementation which supports different - messaging models. It reaches 13.4 microseconds end-to-end latencies and up to - 4,100,000 messages a second today. It requires only a couple of pages in - resident memory. It supports different wire protocols: TCP, PGM, AMQP, and - SCTP. - . - There are C, C++, Lisp, Java, Python, Ruby, and .NET language APis. - . - It is fully distributed: no central servers to crash, millions of WAN and - LAN nodes. It is an extensible framework: kernel-style drivers for custom - hardware, protocols, or applications. - . - This package contains the Ruby bindings for ZeroMQ. - -Package: libzeromq-python -Section: python +Package: libzmq-dev Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: Python language bindings for the ZeroMQ messaging library - ZeroMQ is a very fast, thin messaging implementation which supports different - messaging models. It reaches 13.4 microseconds end-to-end latencies and up to - 4,100,000 messages a second today. It requires only a couple of pages in - resident memory. It supports different wire protocols: TCP, PGM, AMQP, and - SCTP. - . - There are C, C++, Lisp, Java, Python, Ruby, and .NET language APis. - . - It is fully distributed: no central servers to crash, millions of WAN and - LAN nodes. It is an extensible framework: kernel-style drivers for custom - hardware, protocols, or applications. - . - This package contains the Python bindings for ZeroMQ. - -Package: zeromq-examples -Section: misc -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: Example programs for the ZeroMQ messaging library +Section: libdevel +Depends: libzmq0 (= ${binary:Version}), ${misc:Depends} +Description: Development files and static library for the ZeroMQ library ZeroMQ is a very fast, thin messaging implementation which supports different messaging models. It reaches 13.4 microseconds end-to-end latencies and up to - 4,100,000 messages a second today. It requires only a couple of pages in - resident memory. It supports different wire protocols: TCP, PGM, AMQP, and + 4,100,000 messages a second today, requires only a couple of pages in + resident memory and supports different wire protocols: TCP, PGM, AMQP, and SCTP. . - There are C, C++, Lisp, Java, Python, Ruby, and .NET language APis. + There are C, C++, Lisp, Java, Python, Ruby, and .NET language APIs. . It is fully distributed: no central servers to crash, millions of WAN and LAN nodes. It is an extensible framework: kernel-style drivers for custom hardware, protocols, or applications. . - This package contains the ZeroMQ example programs. + This package contains ZeroMQ related development libraries and header files. -Package: zeromq-perf -Section: misc +Package: libzmq-dbg Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: Performance tests for the ZeroMQ messaging library +Priority: extra +Section: debug +Depends: libzmq0 (= ${binary:Version}), ${misc:Depends} +Description: Debugging files for the ZeroMQ messaging library ZeroMQ is a very fast, thin messaging implementation which supports different messaging models. It reaches 13.4 microseconds end-to-end latencies and up to - 4,100,000 messages a second today. It requires only a couple of pages in - resident memory. It supports different wire protocols: TCP, PGM, AMQP, and + 4,100,000 messages a second today, requires only a couple of pages in + resident memory and supports different wire protocols: TCP, PGM, AMQP, and SCTP. . - There are C, C++, Lisp, Java, Python, Ruby, and .NET language APis. + There are C, C++, Lisp, Java, Python, Ruby, and .NET language APIs. . It is fully distributed: no central servers to crash, millions of WAN and LAN nodes. It is an extensible framework: kernel-style drivers for custom hardware, protocols, or applications. . - This package contains the ZeroMQ performance test programs. - + This package contains the debugging synmbols of the ZeroMQ library. diff --git a/debian/copyright b/debian/copyright index 3839b2d..80c2bc6 100644 --- a/debian/copyright +++ b/debian/copyright @@ -1,18 +1,103 @@ -This package was debianized by Peter Busser <[email protected]> on -Tue, 15 Dec 2009 16:11:38 +0100. +This package was debianized by + Adrian von Bidder <[email protected]> + based on earlier work by Peter Busser <[email protected]> -It was downloaded from http://www.zeromq.org/ + The packaging scripts are ©2009-2010 by these authors and are distributed + under the GPL. -Upstream Author(s): iMatix Corporation -Copyright: - Copyright (C) 2007-2010 by iMatix Corporation +Licensing information for 0MQ +----------------------------- + +Project homepage, with original source code: + http://www.zeromq.org/ + +Copyright and Upstream Authors: + + Copyright © 2007-2010 iMatix Corporation + +License: + + This package is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This package 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 + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this package; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +On Debian systems, the complete text of the GNU Lesser General +Public License can be found in `/usr/share/common-licenses/LGPL'. + +iMatrix also offers commercial licenses for 0MQ. + + +Licensing information for the included OpenPGM library +------------------------------------------------------ + +Project homepage, with original source code: + http://code.google.com/p/openpgm/ + +Copyright and Upstream Authors: + Copyright © 2006-2010 Miru Limited. + Copyright © 1995, 1996, 2001, 2003 Free Software Foundation, Inc. + Copyright © 2002, 2003 Andi Kleen, SuSE Labs. License: + Most of OpenPGM is licensed under the terms of the GNU Lesser Public + License, the LGPL, see the file COPYING for details. + + The ultra-high performance partial checksum & folding routines that are + taken from the Linux kernel and licensed under the terms of the GNU General + Public License, the GPL, see the file COPYING.GPL for details. + + Hence you should treat the libraries libpgm, libpgmsnmp, and libpgmhttp of + OpenPGM as being LGPL licensed and the library libpgmplus as being GPL + licensed. + +(Packager's note: "GPL" in the context of the Linux kernel means GPL 2) + +Commercial licenses are also offered. + +On Debian systems, the complete text of the GNU Lesser General +Public License can be found in `/usr/share/common-licenses/LGPL'. + +On Debian systems, the complete text of the GNU General Public +License can be found in `/usr/share/common-licenses/GPL-2'. + + + +Licensing information for the included XMLParser library +-------------------------------------------------------- + +From xmlParser.hpp: -The Debian packaging is (C) 2009, Peter Busser <[email protected]> + Copyright (c) 2002, Frank Vanden Berghen + All rights reserved. -It is licensed under the LGPL3, see `/usr/share/common-licenses/GPL-3' and -`/usr/share/common-licenses/LGPL-3'. + The following license terms apply to projects that are in some way related to + the "ZeroMQ project", including applications + using "ZeroMQ project" and tools developed + for enhancing "ZeroMQ project". All other projects + (not related to "ZeroMQ project") have to use this + code under the Aladdin Free Public License (AFPL) + See the file "AFPL-license.txt" for more informations about the AFPL license. + (see http://www.artifex.com/downloads/doc/Public.htm for detailed AFPL terms) + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + * Neither the name of Frank Vanden Berghen nor the + names of its contributors may be used to endorse or promote products + derived from this software without specific prior written permission. diff --git a/debian/dirs b/debian/dirs deleted file mode 100644 index 07fa48d..0000000 --- a/debian/dirs +++ /dev/null @@ -1,5 +0,0 @@ -usr/share/common-lisp/source -usr/share/common-lisp/systems -usr/share/zeromq/c-perf -usr/share/zeromq/c++-perf -usr/share/zeromq/examples diff --git a/debian/docs b/debian/docs deleted file mode 100644 index 50bd824..0000000 --- a/debian/docs +++ /dev/null @@ -1,2 +0,0 @@ -NEWS -README diff --git a/debian/hgpkg b/debian/hgpkg new file mode 100755 index 0000000..dec7314 --- /dev/null +++ b/debian/hgpkg @@ -0,0 +1,182 @@ +#! /bin/bash +# +# ©2009 Adrian von Bidder +# +# Manage Debian packages stored in Mercurial repositories. +# hgpkg version 1.0 +# (script included here since it's not packaged [yet], maintained by avb in +# a separate repository. Licensing: same as zeromq's packaging.) +# + +set -e +#set -x + +### +# general helpers + +function onlinehelp() { + echo "Commands: + import <path> <version>: import new upstream source + buildfull: build the orig.tar.bz2 and the Debian package + build: build the Debian package + markdeb: tag a version (after upload)" +} + +# get package name from Debian changelog and +# check that 'hg st' generates no output +function preparedir() { + lines=`hg st | wc -l` + if [ "$lines" != "0" ]; then + echo "Error: Mercurial repository is not clean." + exit 1 + fi + + branch=`hg branch` + if [ "$branch" == "upstream" ]; then + echo "Warning: called in upstream branch, switching to default." + hg update -r default >> "$LOG" + branch=`hg branch` + fi + if [ "$branch" != "default" ]; then + echo "Error: must be called in default branch of repository." + exit 1 + fi + + # need to be in root dir: + root=`hg root` + cd "$root" + + PKGNAME=`dpkg-parsechangelog 2>> "$LOG" | grep ^Source: | cut -f 2 -d \ ` + if [ -z "$PKGNAME" ]; then + echo "Error: can't find package name." + exit 1 + fi +} + +### +# subcommands + +# import new upstream version from subversion +# TODO support other vcs and support tar +function cmd_import() { + srcpath="$1" + srcver="$2" + + # check: is source a svn dir? + if [ ! -d "$srcpath/.svn" ]; then + echo "Error: No subversion repository at '$srcpath'." + exit 1 + fi + + # switch to upstream branch + hg update -r upstream >> "$LOG" + br=`hg branch` + if [ "$br" != "upstream" ]; then + echo "Unexpected: I'm not in the upstream branch after update!" + exit 1 + fi + + # check: do we already know about this version? + tag="UPSTREAM_${PKGNAME}_$srcver" + if hg tags | grep -q "$tag"; then + echo "Error: Version already imported: tag '$tag' already exists." + hg update -r default >> "$LOG" + rm "$LOG" # since this is just a user error... + exit 1 + fi + + # ok, now let's be brave: + rm -rf ./* + + # import (--force is needed because .hg dir is still in current dir.) + svn export --force "$srcpath" . >> "$LOG" + + lines=`hg st | wc -l` + if [ "$lines" == "0" ]; then + echo "Error: no changes imported." + hg update -r default >> "$LOG" + rm "$LOG" # since this is just a user error... + exit 1 + fi + + # and commit + hg addremove + hg ci -m "hgpkg import: $PKGNAME $srcver" + hg tag "$tag" + + # start merge into default branch: + hg update -r default >> "$LOG" + # TODO: find a way to auto-fix the expected merge conflict in .hgtags + hg merge upstream || \ + echo "Warning: merge failed." + dch -D UNRELEASED -v "$srcver-1" "New upstream version." + # TODO dch fails if version is older than last version. + # Proper fix would be to check this right at the start of import... + # Leaving this right now since dch fails loudly and the error message + # seems clear enough. + echo "Success: default (Debian) branch left with ucommitted merge." +} + +# build orig tar and build package +function cmd_buildfull() { + # TODO use latest UPSTREAM tag instead? Or at least learn sed properly + # and get rid of the separate grep. + upstream=`dpkg-parsechangelog \ + | grep ^Version: | sed -e's/^Version: \(.*\)-.*/\1/'` + + # use hg archive to build tar + archive="../${PKGNAME}_$upstream.orig.tar.gz" + rm -f "$archive" + hg update -r upstream >> "$LOG" + hg archive -t tgz -X .hgtags -p "$PKGNAME-$upstream" "$archive" + + # run debuild + hg update -r default >> "$LOG" + cmd_build +} + +# just build the Debian package, assume the orig exists and is up to date. +function cmd_build() { + # we're in tip of "default" branch in a clean repository, and mercurial is + # in debuild's default ignore patterns + set +e + debuild -i -I +} + +function cmd_markdeb() { + version=`dpkg-parsechangelog \ + | grep ^Version: | sed -e's/^Version: \(.*\)/\1/'` + hg tag "DEBIAN_${PKGNAME}_$version" +} + +### +# main + +function main() { + cmd="$1" + shift || true + if [ "$cmd" == "import" -a -n "$1" -a -n "$2" ]; then + runcmd="cmd_import" + elif [ "$cmd" == "buildfull" ]; then + runcmd="cmd_buildfull" + elif [ "$cmd" == "build" ]; then + runcmd="cmd_build" + elif [ "$cmd" == "markdeb" ]; then + runcmd="cmd_markdeb" + else + onlinehelp + exit + fi + + # for now: save output of certain commands + LOG=`mktemp` + + preparedir + + $runcmd "$@" + + # on success: + rm "$LOG" +} + +main "$@" diff --git a/debian/libzeromq-dev.files b/debian/libzeromq-dev.files deleted file mode 100644 index 78f55ba..0000000 --- a/debian/libzeromq-dev.files +++ /dev/null @@ -1,37 +0,0 @@ -usr/include/* -usr/lib/lib*.a -usr/lib/lib*.so -usr/lib/pkgconfig/* -usr/lib/*.la -usr/share/pkgconfig/* -usr/share/man/man7/zmq_udp.7 -usr/share/man/man7/zmq_tcp.7 -usr/share/man/man7/zmq_pgm.7 -usr/share/man/man7/zmq.7 -usr/share/man/man7/zmq_cpp.7 -usr/share/man/man7/zmq_inproc.7 -usr/share/man/man3/zmq_msg_copy.3 -usr/share/man/man3/zmq_msg_move.3 -usr/share/man/man3/zmq_send.3 -usr/share/man/man3/zmq_flush.3 -usr/share/man/man3/zmq_msg_init_size.3 -usr/share/man/man3/zmq_msg_data.3 -usr/share/man/man3/zmq_close.3 -usr/share/man/man3/zmq_msg_close.3 -usr/share/man/man3/zmq_term.3 -usr/share/man/man3/zmq_recv.3 -usr/share/man/man3/zmq_init.3 -usr/share/man/man3/zmq_socket.3 -usr/share/man/man3/zmq_msg_init.3 -usr/share/man/man3/zmq_msg_size.3 -usr/share/man/man3/zmq_poll.3 -usr/share/man/man3/zmq_bind.3 -usr/share/man/man3/zmq_connect.3 -usr/share/man/man3/zmq_setsockopt.3 -usr/share/man/man3/zmq_strerror.3 -usr/share/man/man7/zmq_udp.7 -usr/share/man/man7/zmq_tcp.7 -usr/share/man/man7/zmq_pgm.7 -usr/share/man/man7/zmq.7 -usr/share/man/man7/zmq_cpp.7 -usr/share/man/man7/zmq_inproc.7 diff --git a/debian/libzeromq-dev.install b/debian/libzeromq-dev.install deleted file mode 100644 index 7da7950..0000000 --- a/debian/libzeromq-dev.install +++ /dev/null @@ -1,19 +0,0 @@ -usr/include/* usr/include -usr/lib/libzmq.la usr/lib -usr/lib/libzmq.a usr/lib -usr/lib/pkgconfig/libzmq.pc usr/lib/pkgconfig/ -usr/lib/libzmq.so usr/lib/ -usr/share/man/man3/*3 usr/share/man/man3 -usr/share/man/man7/zmq_udp.7 usr/share/man/man7 -usr/share/man/man7/zmq_tcp.7 usr/share/man/man7 -usr/share/man/man7/zmq_pgm.7 usr/share/man/man7 -usr/share/man/man7/zmq.7 usr/share/man/man7 -usr/share/man/man7/zmq_cpp.7 usr/share/man/man7 -usr/share/man/man7/zmq_inproc.7 usr/share/man/man7 -usr/share/man/man7/zmq_udp.7 usr/share/man/man7 -usr/share/man/man7/zmq_tcp.7 usr/share/man/man7 -usr/share/man/man7/zmq_pgm.7 usr/share/man/man7 -usr/share/man/man7/zmq.7 usr/share/man/man7 -usr/share/man/man7/zmq_cpp.7 usr/share/man/man7 -usr/share/man/man7/zmq_inproc.7 usr/share/man/man7 - diff --git a/debian/libzeromq-python.files b/debian/libzeromq-python.files deleted file mode 100644 index 74b2b29..0000000 --- a/debian/libzeromq-python.files +++ /dev/null @@ -1 +0,0 @@ -usr/share/man/man7/zmq_python.7 diff --git a/debian/libzeromq-python.install b/debian/libzeromq-python.install deleted file mode 100644 index a290f70..0000000 --- a/debian/libzeromq-python.install +++ /dev/null @@ -1 +0,0 @@ -usr/share/man/man7/zmq_python.7 usr/share/man/man7/ diff --git a/debian/libzeromq-ruby.files b/debian/libzeromq-ruby.files deleted file mode 100644 index 098bac5..0000000 --- a/debian/libzeromq-ruby.files +++ /dev/null @@ -1 +0,0 @@ -usr/share/man/man7/zmq_ruby.7 diff --git a/debian/libzeromq-ruby.install b/debian/libzeromq-ruby.install deleted file mode 100644 index 681ffab..0000000 --- a/debian/libzeromq-ruby.install +++ /dev/null @@ -1 +0,0 @@ -usr/share/man/man7/zmq_ruby.7 usr/share/man/man7 diff --git a/debian/libzeromq0.files b/debian/libzeromq0.files deleted file mode 100644 index f105647..0000000 --- a/debian/libzeromq0.files +++ /dev/null @@ -1,2 +0,0 @@ -usr/lib/libzmq.so.0 -usr/lib/libzmq.so.0.0.0 diff --git a/debian/libzeromq0.install b/debian/libzeromq0.install deleted file mode 100644 index b25b4ae..0000000 --- a/debian/libzeromq0.install +++ /dev/null @@ -1 +0,0 @@ -usr/lib/libzmq.so.* usr/lib diff --git a/debian/libzmq-dev.install b/debian/libzmq-dev.install new file mode 100644 index 0000000..108aaed --- /dev/null +++ b/debian/libzmq-dev.install @@ -0,0 +1,5 @@ +usr/include/* +usr/lib/libzmq.a +usr/lib/libzmq.la +usr/lib/libzmq.so +usr/lib/pkgconfig/libzmq.pc diff --git a/debian/libzmq-dev.manpages b/debian/libzmq-dev.manpages new file mode 100644 index 0000000..63f4dae --- /dev/null +++ b/debian/libzmq-dev.manpages @@ -0,0 +1,2 @@ +debian/tmp/usr/share/man/man3/* +debian/tmp/usr/share/man/man7/zmq_cpp.7 diff --git a/debian/libzmq0.install b/debian/libzmq0.install new file mode 100644 index 0000000..f63a68f --- /dev/null +++ b/debian/libzmq0.install @@ -0,0 +1 @@ +usr/lib/libzmq.so.* diff --git a/debian/libzmq0.manpages b/debian/libzmq0.manpages new file mode 100644 index 0000000..a38853e --- /dev/null +++ b/debian/libzmq0.manpages @@ -0,0 +1,6 @@ +debian/tmp/usr/share/man/man7/zmq.7 +debian/tmp/usr/share/man/man7/zmq_inproc.7 +debian/tmp/usr/share/man/man7/zmq_ipc.7 +debian/tmp/usr/share/man/man7/zmq_pgm.7 +debian/tmp/usr/share/man/man7/zmq_tcp.7 +debian/tmp/usr/share/man/man7/zmq_udp.7 diff --git a/debian/rules b/debian/rules index bef43f1..d6eb90b 100755 --- a/debian/rules +++ b/debian/rules @@ -1,130 +1,66 @@ #!/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 - - - - - -# shared library versions, option 1 -version=0.0.0 -major=0 - -# option 2, assuming the library is created as src/.libs/libfoo.so.2.0.5 or so -#version=`ls src/.libs/lib*.so.* | \ -# awk '{if (match($$0,/[0-9]+\.[0-9]+\.[0-9]+$$/)) print substr($$0,RSTART)}'` -#major=`ls src/.libs/lib*.so.* | \ -# awk '{if (match($$0,/\.so\.[0-9]+$$/)) print substr($$0,RSTART+4)}'` - - -pkg := cl-zeromq -debpkg := cl-zeromq -clc-source := usr/share/common-lisp/source -clc-systems := usr/share/common-lisp/systems -clc-cl-zeromq := $(clc-source)/$(pkg) - -rubydir := /usr/lib/ruby/1.8/$(shell dpkg-architecture -qDEB_BUILD_GNU_CPU)-$(shell dpkg-architecture -qDEB_BUILD_ARCH_OS) +#export DH_VERBOSE=1 configure: configure-stamp configure-stamp: dh_testdir - # Add here commands to configure the package. - - ./autogen.sh - -ifneq "$(wildcard /usr/share/misc/config.sub)" "" - cp -f /usr/share/misc/config.sub config.sub -endif -ifneq "$(wildcard /usr/share/misc/config.guess)" "" - cp -f /usr/share/misc/config.guess config.guess -endif ./configure $(CROSS) \ - --prefix=/usr \ - --with-c \ - --with-cpp \ - --with-pgm \ - --with-pgm-examples \ - --with-forwarder \ - --with-streamer \ - --with-queue \ - --with-perf \ - --with-chat \ - --mandir=\$${prefix}/share/man \ - --infodir=\$${prefix}/share/info \ - CFLAGS="$(CFLAGS)" \ - LDFLAGS="-Wl,-z,defs" + --prefix=/usr \ + --with-pgm \ + --with-forwarder \ + --with-streamer \ + --with-queue \ + --with-c \ + --with-cpp \ + CFLAGS="$(CFLAGS)" \ + LDFLAGS="-Wl,--as-needed -Wl,-z,defs" \ touch configure-stamp - build: build-stamp -build-stamp: configure-stamp + +build-stamp: configure-stamp dh_testdir - # Add here commands to compile the package. $(MAKE) touch $@ -clean: +clean: dh_testdir dh_testroot rm -f build-stamp configure-stamp - # Add here commands to clean up after the build process. -# $(MAKE) clean + if [ -e Makefile ]; then make distclean; fi + rm -rf foreign/openpgm/libpgm-2.0.20rc5 config.log - dh_clean + dh_clean install: build dh_testdir dh_testroot - dh_clean -k + dh_prep dh_installdirs - # Add here commands to install the package into debian/tmp $(MAKE) DESTDIR=$(CURDIR)/debian/tmp install -# Build architecture-independent files here. - binary-indep: build install -# We have nothing to do by default. -# Build architecture-dependent files here. binary-arch: build install dh_testdir dh_testroot - dh_installchangelogs ChangeLog - dh_installdocs - dh_installexamples -# dh_install --fail-missing - dh_install --list-missing -# dh_installmenu -# dh_installdebconf -# dh_installlogrotate -# dh_installemacsen -# dh_installpam -# dh_installmime -# dh_installinit -# dh_installcron -# dh_installinfo + dh_install -X/usr/share/man --fail-missing dh_installman + dh_installchangelogs + dh_installdocs + dh_lintian dh_link - dh_strip + dh_strip --dbg-package=libzmq-dbg dh_compress dh_fixperms -# dh_perl -# dh_python dh_makeshlibs dh_installdeb dh_shlibdeps @@ -132,5 +68,18 @@ binary-arch: build install dh_md5sums dh_builddeb +# TODO: dh_$language for language bindings, probably. + binary: binary-indep binary-arch .PHONY: build clean binary-indep binary-arch binary install configure + +# vim: set filetype=make + + +# build depends: +# - python[-all]-dev +# - ruby-dev +# -> figure out ruby-headersdir option automatically +# - openjdk-6-jdk (or whatever) +# -> set JAVA_HOME automatically +# - libglib2.0-dev diff --git a/debian/shlibs.local b/debian/shlibs.local deleted file mode 100644 index 0e3fa88..0000000 --- a/debian/shlibs.local +++ /dev/null @@ -1 +0,0 @@ -libzmq 2.0 libzeromq0 (>> 2.0-0), libzeromq0 (<< 2.0-99) diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 0000000..163aaf8 --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +3.0 (quilt) diff --git a/debian/source/options b/debian/source/options new file mode 100644 index 0000000..7423a2d --- /dev/null +++ b/debian/source/options @@ -0,0 +1 @@ +single-debian-patch diff --git a/debian/zeromq-examples.files b/debian/zeromq-examples.files deleted file mode 100644 index f80241c..0000000 --- a/debian/zeromq-examples.files +++ /dev/null @@ -1,2 +0,0 @@ -usr/share/zeromq/examples/display -usr/share/zeromq/examples/prompt diff --git a/debian/zeromq-examples.install b/debian/zeromq-examples.install deleted file mode 100644 index 6031b15..0000000 --- a/debian/zeromq-examples.install +++ /dev/null @@ -1,2 +0,0 @@ -examples/chat/prompt /usr/share/zeromq/examples -examples/chat/display /usr/share/zeromq/examples diff --git a/debian/zeromq-perf.files b/debian/zeromq-perf.files deleted file mode 100644 index 4a79636..0000000 --- a/debian/zeromq-perf.files +++ /dev/null @@ -1,10 +0,0 @@ -usr/share/zeromq/c-perf/local_lat -usr/share/zeromq/c-perf/local_thr -usr/share/zeromq/c-perf/pgmrecv -usr/share/zeromq/c-perf/pgmsend -usr/share/zeromq/c-perf/remote_lat -usr/share/zeromq/c-perf/remote_thr -usr/share/zeromq/c++-perf/local_lat -usr/share/zeromq/c++-perf/local_thr -usr/share/zeromq/c++-perf/remote_thr -usr/share/zeromq/c++-perf/remote_lat diff --git a/debian/zeromq-perf.install b/debian/zeromq-perf.install deleted file mode 100644 index 6048756..0000000 --- a/debian/zeromq-perf.install +++ /dev/null @@ -1,10 +0,0 @@ -perf/c/local_lat usr/share/zeromq/c-perf/ -perf/c/local_thr usr/share/zeromq/c-perf/ -perf/c/pgmrecv usr/share/zeromq/c-perf/ -perf/c/pgmsend usr/share/zeromq/c-perf/ -perf/c/remote_lat usr/share/zeromq/c-perf/ -perf/c/remote_thr usr/share/zeromq/c-perf/ -perf/cpp/local_lat usr/share/zeromq/c++-perf/ -perf/cpp/local_thr usr/share/zeromq/c++-perf/ -perf/cpp/remote_lat usr/share/zeromq/c++-perf/ -perf/cpp/remote_thr usr/share/zeromq/c++-perf/ diff --git a/debian/zeromq-utils.files b/debian/zeromq-utils.files deleted file mode 100644 index c112ff6..0000000 --- a/debian/zeromq-utils.files +++ /dev/null @@ -1,6 +0,0 @@ -usr/bin/zmq_forwarder -usr/bin/zmq_queue -usr/bin/zmq_streamer -usr/share/man/man1/zmq_forwarder.1 -usr/share/man/man1/zmq_queue.1 -usr/share/man/man1/zmq_streamer.1 diff --git a/debian/zeromq-utils.install b/debian/zeromq-utils.install index c2f5776..5c5566e 100644 --- a/debian/zeromq-utils.install +++ b/debian/zeromq-utils.install @@ -1,6 +1,3 @@ -usr/bin/zmq_forwarder /usr/bin -usr/bin/zmq_queue /usr/bin -usr/bin/zmq_streamer /usr/bin -usr/share/man/man1/zmq_forwarder.1 /usr/share/man/man1 -usr/share/man/man1/zmq_queue.1 /usr/share/man/man1 -usr/share/man/man1/zmq_streamer.1 /usr/share/man/man1 +usr/bin/zmq_forwarder +usr/bin/zmq_queue +usr/bin/zmq_streamer diff --git a/debian/zeromq-utils.manpages b/debian/zeromq-utils.manpages new file mode 100644 index 0000000..bcc9687 --- /dev/null +++ b/debian/zeromq-utils.manpages @@ -0,0 +1,3 @@ +debian/tmp/usr/share/man/man1/zmq_forwarder.1 +debian/tmp/usr/share/man/man1/zmq_queue.1 +debian/tmp/usr/share/man/man1/zmq_streamer.1 -- 1.6.5
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ zeromq-dev mailing list [email protected] http://lists.zeromq.org/mailman/listinfo/zeromq-dev
