1 # RPM spec file for GHC -*-rpm-spec-*-
3 # Copyright [1998..2004] The GHC Team
5 # Thanks to Zoltan Vorosbaranyi <vbzoli@vbzo.li> for suggestions in
6 # earlier versions and Pixel <pixel@mandrakesoft.com> for coding tips.
8 # This file is subject to the same free software license as GHC.
10 # Values for @version@ is set by the `configure' script. SNAP releases are
11 # CVS snapshots. Official releases should replace SNAP by an appropriate
12 # release numbers (they are usually numbered starting from 1).
15 %define version @version@
22 Group: Development/Languages/Haskell
23 URL: http://haskell.org/ghc/
24 Source: http://haskell.org/ghc/dist/%{version}/ghc-%{version}-src.tar.bz2
25 BuildRoot: %{_tmppath}/%{name}-%{version}-build
29 BuildRequires: alex >= 2.0, happy >= 1.14, ghc >= 5, haddock, docbk31, jade, jadetex, dvips
30 Summary: Glasgow Haskell Compilation system
33 Haskell is the standard lazy purely functional programming language.
34 The current language version is Haskell 98, agreed in December 1998,
35 with a revised version published in January 2003.
37 GHC is a state-of-the-art programming suite for Haskell. Included is
38 an optimising compiler generating good code for a variety of
39 platforms, together with an interactive system for convenient, quick
40 development. The distribution includes space and time profiling
41 facilities, a large collection of libraries, and support for various
42 language extensions, including concurrency, exceptions, and foreign
43 language interfaces (C, C++, whatever).
45 A wide variety of Haskell related resources (tutorials, libraries,
46 specifications, documentation, compilers, interpreters, references,
47 contact information, links to research groups) are available from the
48 Haskell home page at http://haskell.org/.
52 Krasimir Angelov <ka2_mail@yahoo.com>
53 Manuel Chakravarty <chak@cse.unsw.edu.au>
54 Koen Claessen <koen@cs.chalmers.se>
55 Robert Ennals <Robert.Ennals@cl.cam.ac.uk>
56 Sigbjorn Finne <sof@galconn.com>
57 Gabrielle Keller <keller@cvs.haskell.org>
58 Marcin Kowalczyk <qrczak@knm.org.pl>
59 Jeff Lewis <jeff@galconn.com>
60 Ian Lynagh <igloo@earth.li>
61 Simon Marlow <simonmar@microsoft.com>
62 Sven Panne <sven.panne@aedion.de>
63 Ross Paterson <ross@soi.city.ac.uk>
64 Simon Peyton Jones <simonpj@microsoft.com>
65 Don Stewart <dons@cse.unsw.edu.au>
66 Volker Stolz <stolz@i2.informatik.rwth-aachen.de>
67 Wolfgang Thaller <wolfgang.thaller@gmx.net>
68 Andrew Tolmach <apt@cs.pdx.edu>
69 Keith Wansbrough <Keith.Wansbrough@cl.cam.ac.uk>
70 Michael Weber <michael.weber@post.rwth-aachen.de>
71 plus a dozen helping hands...
74 Summary: Profiling libraries for GHC
75 Group: Development/Libraries
76 Requires: ghc = %{PACKAGE_VERSION}-%{release}
79 Profiling libraries for Glorious Glasgow Haskell Compilation System
80 (GHC). They should be installed when GHC's profiling subsystem is
84 Summary: Documentation for GHC
88 Preformatted documentation for the Glorious Glasgow Haskell
89 Compilation System (GHC) and its libraries. It should be installed if
90 you like to have local access to the documentation in PostScript and
91 HTML format. Alternatively, the documentation is available online at
93 http://haskell.org/ghc/documentation.html
99 test -f configure || autoreconf
100 ./configure --prefix=%{prefix}
105 make prefix=${RPM_BUILD_ROOT}%{prefix} install
107 mkdir -p ${RPM_BUILD_ROOT}%{prefix}/share/doc/ghc-%{version}
108 cp ghc/ANNOUNCE ghc/README ${RPM_BUILD_ROOT}%{prefix}/share/doc/ghc-%{version}
110 make prefix=${RPM_BUILD_ROOT}%{prefix} datadir=${RPM_BUILD_ROOT}%{prefix}/share/doc/ghc-%{version} SGMLDocWays="html ps" install-docs
112 # generate the file list for lib/ _excluding_ all files needed for profiling
115 # * generating file lists in a BUILD_ROOT spec is a bit tricky: the file list
116 # has to contain complete paths, _but_ without the BUILD_ROOT, we also do
117 # _not_ want have directory names in the list; furthermore, we have to make
118 # sure that any leading / is removed from %{prefix}/lib, as find has to
119 # interpret the argument as a relative path; however, we have to include the
120 # leading / again in the final file list (otherwise, rpm complains)
121 # * isn't there an easier way to do all this?
125 libdir=`echo %{prefix}/lib | sed 's|^/||'`
126 find $libdir ! -type d ! -name '*.p_hi' ! -name '*_p.a' -print | sed 's|^|/|' > $dir/rpm-noprof-lib-files
127 find $libdir ! -type d \( -name '*.p_hi' -or -name '*_p.a' \) -print | sed 's|^|/|' > $dir/rpm-prof-lib-files
131 rm -rf ${RPM_BUILD_ROOT}
133 %files -f rpm-noprof-lib-files
134 %defattr(-,root,root)
135 %doc %{prefix}/share/doc/ghc-%{version}/ANNOUNCE
136 %doc %{prefix}/share/doc/ghc-%{version}/README
139 %files prof -f rpm-prof-lib-files
140 %defattr(-,root,root)
143 %defattr(-,root,root)
144 %doc %{prefix}/share/doc/ghc-%{version}/*.ps
145 %doc %{prefix}/share/doc/ghc-%{version}/html