diff --git a/ghc-rpm-macros.spec b/ghc-rpm-macros.spec index 100cf6a..ace5917 100644 --- a/ghc-rpm-macros.spec +++ b/ghc-rpm-macros.spec @@ -10,7 +10,7 @@ #%%global without_hscolour 1 Name: ghc-rpm-macros -Version: 1.6.13 +Version: 1.6.14 Release: 1%{?dist} Summary: RPM macros for building Haskell packages for GHC @@ -147,6 +147,9 @@ EOF %changelog +* Fri Feb 10 2017 Jens Petersen - 1.6.14-1 +- if ghc_subpackaging set configure with --user otherwise --global + * Thu Feb 9 2017 Jens Petersen - 1.6.13-1 - build subpackages inside main package directory diff --git a/macros.ghc b/macros.ghc index 00be8b5..7986970 100644 --- a/macros.ghc +++ b/macros.ghc @@ -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()\ %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} %{!?1:--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_subpackaging:--user} %{!?ghc_subpackaging:--global} %{?ghc_with_lib_for_ghci:--enable-library-for-ghci}\ %cabal build %{?cabal_build_options}\ %{nil} diff --git a/macros.ghc-extra b/macros.ghc-extra index cafbfa2..c0bd7b1 100644 --- a/macros.ghc-extra +++ b/macros.ghc-extra @@ -67,7 +67,7 @@ This package provides the Haskell %{pkgname} library development files.\ # ghc_libs_build [name-version] ... %ghc_libs_build()\ HOME=$PWD\ -%define cabal_configure_options --user\ +%global ghc_subpackaging 1\ for i in %*; do\ name=$(echo $i | sed -e "s/\\(.*\\)-.*/\\1/")\ ver=$(echo $i | sed -e "s/.*-\\(.*\\)/\\1/")\