subpackages can contain numbers and need --user
This commit is contained in:
parent
473b736053
commit
09527a512d
@ -10,7 +10,7 @@
|
|||||||
#%%global without_hscolour 1
|
#%%global without_hscolour 1
|
||||||
|
|
||||||
Name: ghc-rpm-macros
|
Name: ghc-rpm-macros
|
||||||
Version: 1.6.16
|
Version: 1.6.17
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: RPM macros for building Haskell packages for GHC
|
Summary: RPM macros for building Haskell packages for GHC
|
||||||
|
|
||||||
@ -147,6 +147,10 @@ EOF
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Feb 22 2017 Jens Petersen <petersen@redhat.com> - 1.6.17-1
|
||||||
|
- setup --global/--user in cabal_configure
|
||||||
|
- allow subpackage names to contain digits
|
||||||
|
|
||||||
* Wed Feb 22 2017 Jens Petersen <petersen@redhat.com> - 1.6.16-1
|
* Wed Feb 22 2017 Jens Petersen <petersen@redhat.com> - 1.6.16-1
|
||||||
- fix generation of haddock's
|
- fix generation of haddock's
|
||||||
- fix fixing of rpaths for subpackages
|
- fix fixing of rpaths for subpackages
|
||||||
|
@ -31,7 +31,7 @@ fi
|
|||||||
CFLAGS="${CFLAGS:-%optflags}"; export CFLAGS\
|
CFLAGS="${CFLAGS:-%optflags}"; export CFLAGS\
|
||||||
%endif\
|
%endif\
|
||||||
LDFLAGS="${LDFLAGS:-%{?__global_ldflags}}"; export LDFLAGS\
|
LDFLAGS="${LDFLAGS:-%{?__global_ldflags}}"; export LDFLAGS\
|
||||||
%cabal configure --prefix=%{_prefix} --libdir=%{_libdir} --docdir=%{_ghcdocdir} --libsubdir='$compiler/$pkgkey' --datasubdir='$pkgid' --ghc %{!?ghc_without_dynamic:--enable-executable-dynamic} %{?with_tests:--enable-tests} --ghc-options="${CFLAGS:+$(echo ' '$CFLAGS | sed -e 's/ / -optc/g')} ${LDFLAGS:+$(echo ' '$LDFLAGS | sed -e 's/ / -optl/g')}" %{?cabal_configure_options} $cabal_configure_extra_options
|
%cabal configure --prefix=%{_prefix} --libdir=%{_libdir} --docdir=%{_ghcdocdir} --libsubdir='$compiler/$pkgkey' --datasubdir='$pkgid' --ghc %{!?ghc_without_dynamic:--enable-executable-dynamic} %{?with_tests:--enable-tests} %{?ghc_subpackaging:--user}%{!?ghc_subpackaging:--global} --ghc-options="${CFLAGS:+$(echo ' '$CFLAGS | sed -e 's/ / -optc/g')} ${LDFLAGS:+$(echo ' '$LDFLAGS | sed -e 's/ / -optl/g')}" %{?cabal_configure_options} $cabal_configure_extra_options
|
||||||
|
|
||||||
# install
|
# install
|
||||||
%cabal_install %cabal copy --destdir=%{buildroot} %{?cabal_install_options}
|
%cabal_install %cabal copy --destdir=%{buildroot} %{?cabal_install_options}
|
||||||
@ -117,7 +117,7 @@ install -D --mode=0644 %{pkgnamever}.conf %{buildroot}%{ghclibdir}/package.conf.
|
|||||||
# ghc_lib_build_without_haddock [name] [version]
|
# ghc_lib_build_without_haddock [name] [version]
|
||||||
%ghc_lib_build_without_haddock()\
|
%ghc_lib_build_without_haddock()\
|
||||||
%global debug_package %{nil}\
|
%global debug_package %{nil}\
|
||||||
%cabal_configure %{!?without_prof:-p} %{!?ghc_without_shared:--enable-shared} %{?ghc_without_shared:--disable-shared} %{?pkg_name:--htmldir=%{ghclibdocdir}/%{pkg_name}-%{version}} %{?1:--docdir=%{?_defaultlicensedir}%{!?_defaultlicensedir:%_docdir}/ghc-%1%{!?fedora:-%2} --htmldir=%{ghclibdocdir}/%1-%2} %{?ghc_subpackaging:--user}%{!?ghc_subpackaging:--global} %{?ghc_with_lib_for_ghci:--enable-library-for-ghci}\
|
%cabal_configure %{!?without_prof:-p} %{!?ghc_without_shared:--enable-shared} %{?ghc_without_shared:--disable-shared} %{?pkg_name:--htmldir=%{ghclibdocdir}/%{pkg_name}-%{version}} %{?1:--docdir=%{?_defaultlicensedir}%{!?_defaultlicensedir:%_docdir}/ghc-%1%{!?fedora:-%2} --htmldir=%{ghclibdocdir}/%1-%2} %{?ghc_with_lib_for_ghci:--enable-library-for-ghci}\
|
||||||
%cabal build %{?cabal_build_options}\
|
%cabal build %{?cabal_build_options}\
|
||||||
%{nil}
|
%{nil}
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
%ghc_lib_subpackage(c:dl:x)\
|
%ghc_lib_subpackage(c:dl:x)\
|
||||||
%define pkgname %{?2:%{1}}%{!?2:%{lua:\
|
%define pkgname %{?2:%{1}}%{!?2:%{lua:\
|
||||||
local pv = rpm.expand("%1")\
|
local pv = rpm.expand("%1")\
|
||||||
local _, _, name = string.find(pv, "^([%a-]+)-")\
|
local _, _, name = string.find(pv, "^([%a%d-]+)-")\
|
||||||
print(name)\
|
print(name)\
|
||||||
}}\
|
}}\
|
||||||
%define pkgver %{?2}%{!?2:%{lua:\
|
%define pkgver %{?2}%{!?2:%{lua:\
|
||||||
|
Loading…
Reference in New Issue
Block a user