remove braces from rpmspec macros
OBS-URL: https://build.opensuse.org/package/show/devel:languages:ocaml/ocaml-dune?expand=0&rev=76
This commit is contained in:
parent
0e1c756f42
commit
9e7855a505
@ -15,15 +15,15 @@
|
|||||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||||
#
|
#
|
||||||
|
|
||||||
%define build_flavor @BUILD_FLAVOR@%{nil}
|
%define build_flavor @BUILD_FLAVOR@%nil
|
||||||
%if "%{build_flavor}" == ""
|
%if "%build_flavor" == ""
|
||||||
%define nsuffix %{nil}
|
%define nsuffix %nil
|
||||||
%else
|
%else
|
||||||
%define nsuffix -%{build_flavor}
|
%define nsuffix -%build_flavor
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%define pkg ocaml-dune
|
%define pkg ocaml-dune
|
||||||
Name: %{pkg}%{nsuffix}
|
Name: %pkg%nsuffix
|
||||||
Version: 2.9.3
|
Version: 2.9.3
|
||||||
Release: 0
|
Release: 0
|
||||||
%{?ocaml_preserve_bytecode}
|
%{?ocaml_preserve_bytecode}
|
||||||
@ -32,17 +32,17 @@ License: MIT
|
|||||||
Group: Development/Languages/OCaml
|
Group: Development/Languages/OCaml
|
||||||
BuildRoot: %_tmppath/%name-%version-build
|
BuildRoot: %_tmppath/%name-%version-build
|
||||||
URL: https://opam.ocaml.org/packages/dune
|
URL: https://opam.ocaml.org/packages/dune
|
||||||
Source0: %{pkg}-%{version}.tar.xz
|
Source0: %pkg-%version.tar.xz
|
||||||
Requires: ocamlfind(compiler-libs)
|
Requires: ocamlfind(compiler-libs)
|
||||||
BuildRequires: ocaml-rpm-macros >= 20210911
|
BuildRequires: ocaml-rpm-macros >= 20210911
|
||||||
BuildRequires: ocaml(ocaml_base_version) >= 4.08
|
BuildRequires: ocaml(ocaml_base_version) >= 4.08
|
||||||
%if "%{build_flavor}" == ""
|
%if "%build_flavor" == ""
|
||||||
BuildRequires: ocamlfind(compiler-libs)
|
BuildRequires: ocamlfind(compiler-libs)
|
||||||
%description
|
%description
|
||||||
A composable build system for OCaml
|
A composable build system for OCaml
|
||||||
%endif
|
%endif
|
||||||
%if "%{build_flavor}" == "configurator"
|
%if "%build_flavor" == "configurator"
|
||||||
BuildRequires: ocaml-dune = %{version}
|
BuildRequires: ocaml-dune = %version
|
||||||
BuildRequires: ocamlfind(csexp)
|
BuildRequires: ocamlfind(csexp)
|
||||||
BuildRequires: ocamlfind(result)
|
BuildRequires: ocamlfind(result)
|
||||||
%description
|
%description
|
||||||
@ -57,32 +57,32 @@ Among other things, dune-configurator allows one to:
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%package devel
|
%package devel
|
||||||
Summary: Development files for %{name}
|
Summary: Development files for %name
|
||||||
Group: Development/Languages/OCaml
|
Group: Development/Languages/OCaml
|
||||||
Requires: %{name} = %{version}
|
Requires: %name = %version
|
||||||
|
|
||||||
%description devel
|
%description devel
|
||||||
The %{name}-devel package contains libraries and signature files for
|
The %name-devel package contains libraries and signature files for
|
||||||
developing applications that use %{name}.
|
developing applications that use %name.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{pkg}-%{version}
|
%setup -q -n %pkg-%version
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%if "%{build_flavor}" == ""
|
%if "%build_flavor" == ""
|
||||||
mv -vb src/dune_rules/setup.defaults.ml src/dune_rules/setup.ml
|
mv -vb src/dune_rules/setup.defaults.ml src/dune_rules/setup.ml
|
||||||
ocaml configure.ml '--libdir=%{ocaml_standard_library}' '--mandir=%{_mandir}'
|
ocaml configure.ml '--libdir=%ocaml_standard_library' '--mandir=%_mandir'
|
||||||
ocaml bootstrap.ml
|
ocaml bootstrap.ml
|
||||||
rm -rfv '%{_tmppath}/%{name}-%{release}'
|
rm -rfv '%_tmppath/%name-%release'
|
||||||
mkdir -vm 0700 '%{_tmppath}/%{name}-%{release}'
|
mkdir -vm 0700 '%_tmppath/%name-%release'
|
||||||
mkdir -vm 0700 '%{_tmppath}/%{name}-%{release}/bin'
|
mkdir -vm 0700 '%_tmppath/%name-%release/bin'
|
||||||
test -x "$PWD/dune.exe"
|
test -x "$PWD/dune.exe"
|
||||||
ln -vs "$_" '%{_tmppath}/%{name}-%{release}/bin/dune'
|
ln -vs "$_" '%_tmppath/%name-%release/bin/dune'
|
||||||
export "PATH=%{_tmppath}/%{name}-%{release}/bin:$PATH"
|
export "PATH=%_tmppath/%name-%release/bin:$PATH"
|
||||||
dune_release_pkgs='dune,dune-action-plugin,dune-build-info,dune-glob,dune-private-libs'
|
dune_release_pkgs='dune,dune-action-plugin,dune-build-info,dune-glob,dune-private-libs'
|
||||||
%endif
|
%endif
|
||||||
#
|
#
|
||||||
%if "%{build_flavor}" == "configurator"
|
%if "%build_flavor" == "configurator"
|
||||||
dune_release_pkgs='dune-configurator'
|
dune_release_pkgs='dune-configurator'
|
||||||
%endif
|
%endif
|
||||||
#
|
#
|
||||||
@ -90,22 +90,22 @@ dune_release_pkgs='dune-configurator'
|
|||||||
%ocaml_dune_build
|
%ocaml_dune_build
|
||||||
|
|
||||||
%install
|
%install
|
||||||
export "PATH=%{_tmppath}/%{name}-%{release}/bin:$PATH"
|
export "PATH=%_tmppath/%name-%release/bin:$PATH"
|
||||||
%ocaml_dune_install
|
%ocaml_dune_install
|
||||||
%ocaml_create_file_list
|
%ocaml_create_file_list
|
||||||
rm -rfv '%{_tmppath}/%{name}-%{release}'
|
rm -rfv '%_tmppath/%name-%release'
|
||||||
|
|
||||||
%files -f %{name}.files
|
%files -f %name.files
|
||||||
%defattr(-,root,root,-)
|
%defattr(-,root,root,-)
|
||||||
%if "%{build_flavor}" == ""
|
%if "%build_flavor" == ""
|
||||||
%doc CHANGES.md README.md
|
%doc CHANGES.md README.md
|
||||||
%doc doc/*.rst
|
%doc doc/*.rst
|
||||||
%{_bindir}/*
|
%_bindir/*
|
||||||
%{_mandir}/*/*
|
%_mandir/*/*
|
||||||
%{_datadir}/emacs
|
%_datadir/emacs
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%files devel -f %{name}.files.devel
|
%files devel -f %name.files.devel
|
||||||
%defattr(-,root,root,-)
|
%defattr(-,root,root,-)
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Loading…
Reference in New Issue
Block a user