-
Notifications
You must be signed in to change notification settings - Fork 0
/
libvhcall-fortran.spec.in
82 lines (70 loc) · 2.09 KB
/
libvhcall-fortran.spec.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
%if "%{_ve_arch}" == "ve3"
Name: @PACKAGE_NAME@-ve3
%else
Name: @PACKAGE_NAME@-ve1
%endif
Obsoletes: @PACKAGE_NAME@
Version: @PACKAGE_VERSION@
Release: @RELEASE@%{?dist}
Summary: VHcall Fortran library
Group: System Environment/Libraries
License: MIT
#ULI:
Source0: @PACKAGE_NAME@-@PACKAGE_VERSION@.tar.gz
Vendor: NEC Corporation
BuildArch: x86_64
BuildRequires: vedebuginfo
%if "%{_ve_arch}" == "ve3"
BuildRequires: libsysve-ve3-devel
%else
BuildRequires: libsysve-ve1-devel
Obsoletes: libvhcall-fortran
Provides: libvhcall-fortran
%endif
%description
The libvhcall-fortran package contains a library which is used by VE
programs to invoke Fortran subroutine or function on VH side.
%package devel
Summary: Headers for libvhcall-fortran
Requires: %{name} = %{version}-%{release}
%if "%{_ve_arch}" != "ve3"
Obsoletes: libvhcall-fortran-devel
Provides: libvhcall-fortran-devel
%endif
%description devel
This package contains the files required to build VE programs that use
libraries in libvhcall-fortran package
%define _prefix @prefix@
%define _libdir @prefix@/lib
%define __strip /opt/nec/ve/bin/nstrip
%if 0%{?rhel} == 8
%global __debug_install_post /opt/nec/ve/libexec/find-debuginfo.sh --unique-debug-suffix "-%{VERSION}-%{RELEASE}.%{_arch}" -S debugsourcefiles.list %{_builddir}/%{buildsubdir} %{nil}
%else
%global __debug_install_post /opt/nec/ve/libexec/find-debuginfo.sh %{nil}
%endif
%define __requires_exclude ^libn(cc|c\\+\\+|fort)\\.so\\..*$
%prep
%{__rm} -rf ${RPM_BUILD_ROOT}
%setup -q -n @PACKAGE_NAME@-@PACKAGE_VERSION@
%build
./configure --host=ve-nec-linux \
--prefix=%{_prefix} \
CC=@CC@ FC=@FC@
sed -i -e 's/^wl=""$/wl="-Wl,"/g' libtool # workaround to specify "-Wl,soname=xxx' instead of "soname=xxx
make
%install
make install DESTDIR=${RPM_BUILD_ROOT}
%clean
ls -l %{_libdir}
%{__rm} -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%{_libdir}/*.so.*
%files devel
%defattr(-,root,root,-)
%doc
%{_includedir}/*.mod
%{_libdir}/*.a
%{_libdir}/*.la
%{_libdir}/*.so
%changelog