]> git.pld-linux.org Git - SPECS.git/blob - storj-uplink-c.spec
SPECS updated Wed 28 Jul 14:48:01 CEST 2021
[SPECS.git] / storj-uplink-c.spec
1 #
2 # Conditional build:
3 %bcond_with     gpl2    # GPL v2 compatible package (drop Apache v2 licensed components)
4
5 Summary:        C library for Storj V3 Network
6 Summary(pl.UTF-8):      Biblioteka C do sieci Storj V3
7 Name:           storj-uplink-c
8 Version:        1.2.0
9 Release:        1
10 License:        MIT, other (used go components)
11 Group:          Libraries
12 #Source0Download: https://github.com/storj/uplink-c/releases
13 Source0:        https://github.com/storj/uplink-c/archive/v%{version}/uplink-c-%{version}.tar.gz
14 # Source0-md5:  fd3b321db1b48839f58ca8da896f17b1
15 Patch0:         %{name}-libdir.patch
16 URL:            https://github.com/storj/uplink-c
17 BuildRequires:  golang >= 1.13
18 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
19
20 %description
21 C library for Storj V3 Network.
22
23 %description -l pl.UTF-8
24 Biblioteka C do sieci Storj V3.
25
26 %package devel
27 Summary:        Header files for Storj uplink library
28 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki Storj uplink
29 Group:          Development/Libraries
30 Requires:       %{name} = %{version}-%{release}
31
32 %description devel
33 Header files for Storj uplink library.
34
35 %description devel -l pl.UTF-8
36 Pliki nagłówkowe biblioteki Storj uplink.
37
38 %package static
39 Summary:        Static Storj uplink library
40 Summary(pl.UTF-8):      Statyczna biblioteka Storj uplink
41 Group:          Development/Libraries
42 Requires:       %{name}-devel = %{version}-%{release}
43
44 %description static
45 Static Storj uplink library.
46
47 %description static -l pl.UTF-8
48 Statyczna biblioteka Storj uplink.
49
50 %prep
51 %setup -q -n uplink-c-%{version}
52 %patch0 -p1
53
54 cat > scripts/version <<EOF
55 #!/bin/sh
56 echo %{version}
57 EOF
58
59 sed -i -e 's,^prefix=.*,prefix=%{_prefix},' \
60         -e 's,^libdir=.*,libdir=%{_libdir},' scripts/gen-pkg-config
61
62 %build
63 %{__make} build \
64         %{?with_gpl2:GPL2=true}
65
66 %install
67 rm -rf $RPM_BUILD_ROOT
68
69 %{__make} install \
70         DESTDIR=$RPM_BUILD_ROOT \
71         PREFIX=%{_prefix} \
72         LIBDIR=%{_libdir}
73
74 %clean
75 rm -rf $RPM_BUILD_ROOT
76
77 %post   -p /sbin/ldconfig
78 %postun -p /sbin/ldconfig
79
80 %files
81 %defattr(644,root,root,755)
82 %doc LICENSE README.md
83 %attr(755,root,root) %{_libdir}/libuplink.so
84
85 %files devel
86 %defattr(644,root,root,755)
87 %{_includedir}/uplink
88 %{_pkgconfigdir}/libuplink.pc
89
90 %files static
91 %defattr(644,root,root,755)
92 %{_libdir}/libuplink.a
This page took 0.198043 seconds and 3 git commands to generate.