use the same CFLAGS as ocaml would use
OBS-URL: https://build.opensuse.org/package/show/devel:languages:ocaml/ocaml-stdcompat?expand=0&rev=12
This commit is contained in:
parent
0495cf4a1d
commit
8e3c27fb93
@ -16,6 +16,7 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
|
%global _buildshell /bin/bash
|
||||||
%define _lto_cflags %{nil}
|
%define _lto_cflags %{nil}
|
||||||
Name: ocaml-stdcompat
|
Name: ocaml-stdcompat
|
||||||
Version: 15
|
Version: 15
|
||||||
@ -28,6 +29,7 @@ URL: https://opam.ocaml.org/packages/stdcompat
|
|||||||
Source0: %{name}-%{version}.tar.xz
|
Source0: %{name}-%{version}.tar.xz
|
||||||
BuildRequires: autoconf
|
BuildRequires: autoconf
|
||||||
BuildRequires: automake
|
BuildRequires: automake
|
||||||
|
BuildRequires: bash
|
||||||
BuildRequires: ocamlfind(findlib)
|
BuildRequires: ocamlfind(findlib)
|
||||||
BuildRequires: ocaml-rpm-macros >= 20210409
|
BuildRequires: ocaml-rpm-macros >= 20210409
|
||||||
BuildRequires: ocaml(ocaml.opt)
|
BuildRequires: ocaml(ocaml.opt)
|
||||||
@ -48,6 +50,10 @@ developing applications that use %{name}.
|
|||||||
%autosetup -p1
|
%autosetup -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
|
values=( `ocamlc.opt -config-var native_c_compiler` )
|
||||||
|
export CC="${values[0]}"
|
||||||
|
unset values[0]
|
||||||
|
export CFLAGS="${values[@]}"
|
||||||
%make_build -f Makefile.bootstrap
|
%make_build -f Makefile.bootstrap
|
||||||
%configure \
|
%configure \
|
||||||
--libdir=%{ocaml_standard_library}
|
--libdir=%{ocaml_standard_library}
|
||||||
|
Loading…
Reference in New Issue
Block a user