packages: ghc-terminfo/ghc-terminfo.spec (NEW) - initial revision

baggins baggins at pld-linux.org
Sat Apr 10 20:13:22 CEST 2010


Author: baggins                      Date: Sat Apr 10 18:13:22 2010 GMT
Module: packages                      Tag: HEAD
---- Log message:
- initial revision

---- Files affected:
packages/ghc-terminfo:
   ghc-terminfo.spec (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: packages/ghc-terminfo/ghc-terminfo.spec
diff -u /dev/null packages/ghc-terminfo/ghc-terminfo.spec:1.1
--- /dev/null	Sat Apr 10 20:13:22 2010
+++ packages/ghc-terminfo/ghc-terminfo.spec	Sat Apr 10 20:13:17 2010
@@ -0,0 +1,76 @@
+# $Revision$, $Date$
+%define	pkgname	terminfo
+Summary:	Haskell bindings to the terminfo library
+Name:		ghc-%{pkgname}
+Version:	0.3.1.2
+Release:	1
+License:	BSD
+Group:		Development/Languages
+Source0:	http://hackage.haskell.org/packages/archive/%{pkgname}/%{version}/%{pkgname}-%{version}.tar.gz
+# Source0-md5:	5840d32cc06109d23ebda5509fb242a9
+URL:		http://hackage.haskell.org/package/%{pkgname}/
+BuildRequires:	ghc >= 6.10
+BuildRequires:	ncurses-devel
+%requires_eq	ghc
+Requires:	ncurses-devel
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%define		libsubdir	ghc-%(/usr/bin/ghc --numeric-version)/%{pkgname}-%{version}
+
+%description
+This library provides an interface to the terminfo database
+(via bindings to the curses library). Terminfo allows POSIX
+systems to interact with a variety of terminals using
+a standard set of capabilities. 
+
+%prep
+%setup -q -n %{pkgname}-%{version}
+
+%build
+runhaskell Setup.lhs configure -v2 \
+	--prefix=%{_prefix} \
+	--libdir=%{_libdir} \
+	--libexecdir=%{_libexecdir} \
+	--libsubdir=%{libsubdir} \
+	--docdir=%{_docdir}/%{name}-%{version} \
+	--configure-option="--with-curses-includes=/usr/include/ncursesw"
+
+runhaskell Setup.lhs build
+runhaskell Setup.lhs haddock --executables
+
+%install
+rm -rf $RPM_BUILD_ROOT
+runhaskell Setup.lhs copy --destdir=$RPM_BUILD_ROOT
+
+# work around automatic haddock docs installation
+rm -rf %{name}-%{version}-doc
+cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
+
+runhaskell Setup.lhs register \
+	--gen-pkg-config=$RPM_BUILD_ROOT/%{_libdir}/%{libsubdir}/%{pkgname}.conf
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post
+/usr/bin/ghc-pkg update %{_libdir}/%{libsubdir}/%{pkgname}.conf
+
+%postun
+if [ "$1" = "0" ]; then
+	/usr/bin/ghc-pkg unregister %{pkgname}-%{version}
+fi
+
+%files
+%defattr(644,root,root,755)
+%doc %{name}-%{version}-doc/html
+%{_libdir}/%{libsubdir}
+
+%define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
+%changelog
+* %{date} PLD Team <feedback at pld-linux.org>
+All persons listed below can be reached at <cvs_login>@pld-linux.org
+
+$Log$
+Revision 1.1  2010/04/10 18:13:17  baggins
+- initial revision
+
================================================================


More information about the pld-cvs-commit mailing list