The package rpms/ocaml-dune.git has added or updated architecture specific content in its
spec file (ExclusiveArch/ExcludeArch or %ifarch/%ifnarch) in commit(s):
https://src.fedoraproject.org/cgit/rpms/ocaml-dune.git/commit/?id=e1c4ce1....
Change:
+%ifarch %{ocaml_native_compiler}
Thanks.
Full change:
============
commit e1c4ce182df791b0d26196dadd80e80d4d4c40de
Author: Ben Rosser <rosser.bjr(a)gmail.com>
Date: Tue Aug 6 14:33:41 2019 -0400
Add new development subpackage. Install all compiled dune libraries.
diff --git a/ocaml-dune.spec b/ocaml-dune.spec
index a227fe7..65cbc61 100644
--- a/ocaml-dune.spec
+++ b/ocaml-dune.spec
@@ -1,6 +1,6 @@
Name: ocaml-dune
Version: 1.10.0
-Release: 4%{?dist}
+Release: 5%{?dist}
Summary: A composable build system for OCaml
%global libname %(echo %{name} | sed -e 's/^ocaml-//')
@@ -11,7 +11,6 @@ License: MIT and LGPLv2 with exceptions and ISC
URL:
https://dune.build
Source0:
https://github.com/ocaml/%{libname}/archive/%{version}/%{libname}-%{versi...
-
BuildRequires: ocaml >= 4.02.3
BuildRequires: ocaml-findlib-devel
@@ -49,6 +48,14 @@ adapted to the open source world. It has matured over a long time and
is used
daily by hundred of developers, which means that it is highly tested and
productive.
+%package devel
+Summary: Development files for %{name}
+Requires: %{name}%{?isa} = %{version}-%{release}
+
+%description devel
+The %{name}-devel package contains libraries and
+signature files for developing applications that use %{name}.
+
%package doc
Summary: HTML documentation for %{name}
Requires: %{name} = %{version}-%{release}
@@ -82,6 +89,17 @@ ln -sfvbn dune %{buildroot}%{_bindir}/jbuilder
cp -av _boot/default/doc/*.1 %{buildroot}%{_mandir}/man1/
cp -av _boot/default/doc/*.5 %{buildroot}%{_mandir}/man5/
+# Dune also has libraries now, which need to be installed via the standard way.
+mkdir -p %{buildroot}%{_libdir}/ocaml/%{libname}/
+cp -aLr _boot/install/default/lib/%{libname}/* %{buildroot}%{_libdir}/ocaml/%{libname}/
+
+# Remove *.ml files from installation.
+# This is a little annoying. ocaml/dune has a bunch of subdirectories that actually
contain code.
+# But the "_wp" subdirectory *itself* contains subdirectories with compiled
code.
+# So I've special-cased that one.
+rm -fv %{buildroot}%{_libdir}/ocaml/%{libname}/*/*.ml
+rm -fv %{buildroot}%{_libdir}/ocaml/%{libname}/_wp/*/*.ml
+
# Install documentation by way of pkgdocdir.
mkdir -p %{buildroot}%{_pkgdocdir}/
cp -ar README.md CHANGES.md doc/_build/* %{buildroot}%{_pkgdocdir}/
@@ -99,6 +117,30 @@ cp -ar README.md CHANGES.md doc/_build/* %{buildroot}%{_pkgdocdir}/
%{_bindir}/dune
%{_mandir}/man*/dune*
%dir %{_pkgdocdir}
+%{_libdir}/ocaml/%{libname}
+%ifarch %{ocaml_native_compiler}
+%exclude %{_libdir}/ocaml/%{libname}/*/*.a
+%exclude %{_libdir}/ocaml/%{libname}/*/*.cmxa
+%exclude %{_libdir}/ocaml/%{libname}/*/*.cmx
+%exclude %{_libdir}/ocaml/%{libname}/_wp/*/*.a
+%exclude %{_libdir}/ocaml/%{libname}/_wp/*/*.cmxa
+%exclude %{_libdir}/ocaml/%{libname}/_wp/*/*.cmx
+%endif
+%exclude %{_libdir}/ocaml/%{libname}/*/*.mli
+%exclude %{_libdir}/ocaml/%{libname}/_wp/*/*.mli
+
+%files devel
+%ifarch %{ocaml_native_compiler}
+%{_libdir}/ocaml/%{libname}/*/*.a
+%{_libdir}/ocaml/%{libname}/*/*.cmxa
+%{_libdir}/ocaml/%{libname}/*/*.cmx
+%{_libdir}/ocaml/%{libname}/_wp/*/*.a
+%{_libdir}/ocaml/%{libname}/_wp/*/*.cmxa
+%{_libdir}/ocaml/%{libname}/_wp/*/*.cmx
+%endif
+%{_libdir}/ocaml/%{libname}/*/*.mli
+# There do not seem to be headers in the _wp subdirectory.
+#{_libdir}/ocaml/{libname}/_wp/*/*.mli
%files doc
%exclude %{_pkgdocdir}/README.md
@@ -106,6 +148,9 @@ cp -ar README.md CHANGES.md doc/_build/* %{buildroot}%{_pkgdocdir}/
%doc %{_pkgdocdir}/*
%changelog
+* Tue Aug 06 2019 Ben Rosser <rosser.bjr(a)gmail.com> - 1.10.0-5
+- Install dune libraries. Add new ocaml-dune subpackage (rhbz#1737414).
+
* Wed Jul 31 2019 Richard W.M. Jones <rjones(a)redhat.com> - 1.10.0-4
- OCaml 4.08.1 (rc2) rebuild.