]> git.pld-linux.org Git - packages/ghc-socks.git/blame - ghc-socks.spec
rebuild with ghc 8.10.7
[packages/ghc-socks.git] / ghc-socks.spec
CommitLineData
044429a9
JR
1#
2# Conditional build:
3%bcond_without prof # profiling library
4#
5%define pkgname socks
6Summary: Socks proxy (ver 5)
7Name: ghc-%{pkgname}
8Version: 0.6.1
b269312a 9Release: 2
044429a9
JR
10License: BSD
11Group: Development/Languages
12#Source0Download: http://hackage.haskell.org/package/socks
13Source0: http://hackage.haskell.org/package/%{pkgname}-%{version}/%{pkgname}-%{version}.tar.gz
14# Source0-md5: e85be2113ecf285060ce2c3678bcd9dc
15URL: http://hackage.haskell.org/package/socks
16BuildRequires: ghc >= 6.12.3
17BuildRequires: ghc-basement
18BuildRequires: ghc-cereal >= 0.3.1
19BuildRequires: ghc-network >= 2.6
20%if %{with prof}
21BuildRequires: ghc-prof
22BuildRequires: ghc-basement-prof
23BuildRequires: ghc-cereal-prof >= 0.3.1
24BuildRequires: ghc-network-prof >= 2.6
25%endif
26BuildRequires: rpmbuild(macros) >= 1.608
27%requires_eq ghc
28Requires(post,postun): /usr/bin/ghc-pkg
29Requires: ghc-basement
30Requires: ghc-cereal >= 0.3.1
31Requires: ghc-network >= 2.6
32BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34# debuginfo is not useful for ghc
35%define _enable_debug_packages 0
36
37# don't compress haddock files
38%define _noautocompressdoc *.haddock
39
40%description
41Socks proxy (version 5) implementation.
42
43%package prof
44Summary: Profiling %{pkgname} library for GHC
45Summary(pl.UTF-8): Biblioteka profilująca %{pkgname} dla GHC
46Group: Development/Libraries
47Requires: %{name} = %{version}-%{release}
48Requires: ghc-basement-prof
49Requires: ghc-cereal-prof >= 0.3.1
50Requires: ghc-network-prof >= 2.6
51
52%description prof
53Profiling %{pkgname} library for GHC. Should be installed when
54GHC's profiling subsystem is needed.
55
56%description prof -l pl.UTF-8
57Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
58kiedy potrzebujemy systemu profilującego z GHC.
59
60%prep
61%setup -q -n %{pkgname}-%{version}
62
63%build
64runhaskell Setup.hs configure -v2 \
65 %{?with_prof:--enable-library-profiling} \
66 --prefix=%{_prefix} \
67 --libdir=%{_libdir} \
68 --libexecdir=%{_libexecdir} \
69 --docdir=%{_docdir}/%{name}-%{version}
70
71runhaskell Setup.hs build
72runhaskell Setup.hs haddock --executables
73
74%install
75rm -rf $RPM_BUILD_ROOT
76install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
77
78runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
79
80# work around automatic haddock docs installation
81%{__rm} -rf %{name}-%{version}-doc
82cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
83%{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
84
85runhaskell Setup.hs register \
86 --gen-pkg-config=$RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
87
88%clean
89rm -rf $RPM_BUILD_ROOT
90
91%post
92%ghc_pkg_recache
93
94%postun
95%ghc_pkg_recache
96
97%files
98%defattr(644,root,root,755)
99%doc README.md %{name}-%{version}-doc/*
100%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
101%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
102%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.so
103%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.a
104%exclude %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
105
106%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Network
107%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Network/*.hi
108%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Network/*.dyn_hi
109%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Network/Socks5
110%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Network/Socks5/*.hi
111%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Network/Socks5/*.dyn_hi
112
113%if %{with prof}
114%files prof
115%defattr(644,root,root,755)
116%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
117%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Network/*.p_hi
118%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Network/Socks5/*.p_hi
119%endif
This page took 0.093872 seconds and 4 git commands to generate.