Commit fb6f7ce6 authored by ijones's avatar ijones
Browse files

patches from John Goerzen for better debian support

parent a35d80b5
haskell-cabal (0.0.1-2) unstable; urgency=low
haskell-cabal (0.1-4) unstable; urgency=low
* Cleaned up scripts and name of binary.
* Added basic infrastructure for multiple targets, though
have not yet enabled it because it doesn't yet work upstream.
-- Isaac Jones <ijones@debian.org> Thu, 29 Jul 2004 10:37:31 -0400
-- John Goerzen <jgoerzen@complete.org> Tue, 5 Oct 2004 19:45:27 -0500
haskell-cabal (0.0.1-1) unstable; urgency=low
haskell-cabal (0.1-3) unstable; urgency=low
* Initial Release.
* Fixed old postinst, postrm scripts to do the right thing in more cases.
-- John Goerzen <jgoerzen@complete.org> Tue, 5 Oct 2004 16:25:29 -0500
haskell-cabal (0.1-2) unstable; urgency=low
* Install binary under /usr/lib/haskell-libraries/ghc6 in keeping
with new Haskell policy.
-- John Goerzen <jgoerzen@complete.org> Tue, 5 Oct 2004 15:56:03 -0500
haskell-cabal (0.1-1) unstable; urgency=low
* Initial release. Closes: #275069.
-- John Goerzen <jgoerzen@complete.org> Tue, 05 Oct 2004 13:36:08 -0500
-- Isaac Jones <ijones@debian.org> Wed, 28 Jul 2004 22:29:38 -0400
Source: haskell-cabal
Priority: optional
Maintainer: Isaac Jones <ijones@debian.org>
Build-Depends: debhelper (>= 4.0.0), ghc6 (> 6.2)
Maintainer: John Goerzen <jgoerzen@complete.org>
Build-Depends: debhelper (>= 4.0.0), ghc6 (>= 6.2.1), ghc6 (<< 6.2.2), ghc5 (>= 5.04.3), ghc5 (<< 5.04.4)
Standards-Version: 3.6.0
Package: libghc6-cabal-dev
Section: devel
Architecture: any
Depends: ghc6 (>= 6.2.1), ghc6 (<< 6.2.2)
Description: Haskell Common Architecture for Building Applications and Libraries
Haskell Common Architecture for Building Applications and Libraries
The Haskell Cabal is a system for building and installing Haskell
programs and libraries. It is aware of multiple different compilers
and can handle them without trouble.
.
This package will provide the infrastructure necessary to build
Cabalized packages on Debian machines, or to Debianize those packages.
This package was debianized by Isaac Jones <ijones@debian.org> on
Wed, 28 Jul 2004 22:29:38 -0400.
It was downloaded from <fill in ftp site>
John Goerzen updated it for sid in October 5, 2004.
Upstream Author(s): Isaac, Marvin, Simon, etc.
It was downloaded from http://www.haskell.org/cabal/code.html
Upstream Author(s): Bjorn Bringert, Isaac Jones, Simon Marlow,
Martin Sjögren
Copyright:
BSD-Like
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 Isaac Jones nor the names of other
contributors may be used to endorse or promote products derived
from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#!/bin/sh -e
#! /bin/sh
# postinst script for missingh
#
# see: dh_installdeb(1)
ghc-pkg -g --add-package \
< /usr/share/doc/libghc6-cabal-dev/installed-pkg-config
set -e
# summary of how this script can be called:
# * <postinst> `configure' <most-recently-configured-version>
# * <old-postinst> `abort-upgrade' <new version>
# * <conflictor's-postinst> `abort-remove' `in-favour' <package>
# <new-version>
# * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
# <failed-install-package> <version> `removing'
# <conflicting-package> <version>
# for details, see http://www.debian.org/doc/debian-policy/ or
# the debian-policy package
#
case "$1" in
configure)
/usr/lib/ghc-6.2.1/bin/ghc-pkg-6.2.1 -g --add-package \
< /usr/share/doc/libghc6-cabal-dev/installed-pkg-config
;;
abort-upgrade|abort-remove|abort-deconfigure)
;;
*)
echo "postinst called with unknown argument \`$1'" >&2
exit 1
;;
esac
# dh_installdeb will replace this with shell code automatically
# generated by other debhelper scripts.
#DEBHELPER#
exit 0
#!/bin/sh -e
#! /bin/sh
# prerm script for missingh
#
# see: dh_installdeb(1)
ghc-pkg -r Cabal
# ditch that ghci library:
rm /usr/lib/Cabal-0.1/HSCabal-0.1.o
set -e
# summary of how this script can be called:
# * <prerm> `remove'
# * <old-prerm> `upgrade' <new-version>
# * <new-prerm> `failed-upgrade' <old-version>
# * <conflictor's-prerm> `remove' `in-favour' <package> <new-version>
# * <deconfigured's-prerm> `deconfigure' `in-favour'
# <package-being-installed> <version> `removing'
# <conflicting-package> <version>
# for details, see http://www.debian.org/doc/debian-policy/ or
# the debian-policy package
case "$1" in
remove|upgrade|deconfigure)
/usr/lib/ghc-6.2.1/bin/ghc-pkg-6.2.1 -r Cabal
rm /usr/lib/haskell-packages/ghc6/lib/Cabal-0.1/HSCabal*.o
# install-info --quiet --remove /usr/info/missingh.info.gz
;;
failed-upgrade)
;;
*)
echo "prerm called with unknown argument \`$1'" >&2
exit 1
;;
esac
# dh_installdeb will replace this with shell code automatically
# generated by other debhelper scripts.
#DEBHELPER#
exit 0
......@@ -6,11 +6,28 @@
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
GHCVERSION=6.2.1
GHCPATH=/usr/lib/ghc-$(GHCVERSION)/bin
PATH:=$(GHCPATH):$(PATH)
export PATH
CFLAGS = -Wall -g
CABAL_BIN=libghc6-cabal-dev
LIBPATH=/usr/lib/haskell-packages/$(1)
PACKAGE=lib$(1)-cabal-dev
FLAVORS=ghc6
define build_flavor
echo BUILDING FOR $(1)
-./setup clean
rm -f .*config*
./setup configure --prefix=$(LIBPATH) --with-compiler=/usr/bin/$(1)
./setup build
mkdir -p $(CURDIR)/debian/$(PACKAGE)/usr/share/doc/$(PACKAGE)
./setup install --install-prefix=$(CURDIR)/debian/$(PACKAGE)$(LIBPATH)
cp .installed-pkg-config $(CURDIR)/debian/$(PACKAGE)/usr/share/doc/$(PACKAGE)/installed-pkg-config
endef
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
......@@ -34,8 +51,7 @@ configure: configure-stamp
configure-stamp:
dh_testdir
# Add here commands to configure the package.
make setup #bootstrap
./setup configure --prefix=/usr --ghc
make setup
touch configure-stamp
......@@ -44,7 +60,6 @@ build-stamp: configure-stamp
dh_testdir
# Add here commands to compile the package.
./setup build
touch build-stamp
clean:
......@@ -55,6 +70,7 @@ clean:
# Add here commands to clean up after the build process.
-$(MAKE) clean
rm -f .*config*
dh_clean
install: build
......@@ -63,11 +79,7 @@ install: build
dh_clean -k
dh_installdirs
# Add here commands to install the package into debian/$(CABAL_BIN)
mkdir -p $(CURDIR)/debian/$(CABAL_BIN)/usr/share/doc/$(CABAL_BIN)
./setup install --install-prefix=$(CURDIR)/debian/$(CABAL_BIN)/usr
cp .installed-pkg-config $(CURDIR)/debian/$(CABAL_BIN)/usr/share/doc/$(CABAL_BIN)/installed-pkg-config
$(foreach tgt,$(FLAVORS),$(call build_flavor,$(tgt)))
# Build architecture-independent files here.
binary-indep: build install
......@@ -77,9 +89,9 @@ binary-indep: build install
binary-arch: build install
dh_testdir
dh_testroot
dh_installchangelogs
dh_installdocs
dh_installexamples
dh_installchangelogs -a
dh_installdocs -a
dh_installexamples -a
# dh_install
# dh_installmenu
# dh_installdebconf
......@@ -90,19 +102,19 @@ binary-arch: build install
# dh_installinit
# dh_installcron
# dh_installinfo
dh_installman
dh_link
dh_strip
dh_compress
dh_fixperms
dh_installman -a
dh_link -a
dh_strip -a
dh_compress -a
dh_fixperms -a
# dh_perl
# dh_python
# dh_makeshlibs
dh_installdeb
dh_shlibdeps
dh_gencontrol
dh_md5sums
dh_builddeb
dh_installdeb -a
dh_shlibdeps -a
dh_gencontrol -a
dh_md5sums -a
dh_builddeb -a
binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install configure
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment