-
Notifications
You must be signed in to change notification settings - Fork 2
/
libkrisp.spec.in
97 lines (78 loc) · 2.64 KB
/
libkrisp.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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
%define _unpackaged_files_terminate_build 0
%define sqlitepkgname sqlite
@RPM_COMPAT_DEFINE@
Summary: Korean ISP library
Summary(ko): 한국 ISP 라이브러리
Name: libkrisp%{?compat}
Version: @PACKAGE_VERSION@
Release: 1
Epoch: 1
License: LGPL
Group: System Environment/Libraries
Requires: %{sqlitepkgname} libipcalc
BuildRequires: %{sqlitepkgname}-devel libipcalc-devel
Source0: https://github.com/Joungkyun/libkrisp/archive/3.1.5.tar.gz/#%{name}-%{version}.tar.gz
URL: https://github.com/joungkyun/libkrisp
Buildroot: /var/tmp/%{name}-%{version}-root
%description
The libkrisp%{?compat} is library that get Korean IPS information from IP address.
%description -l ko
libkrisp%{?compat} 는 IP 주소로 부터 한국 ISP 정보를 얻기 위한 라이브러리이다.
%package devel
Summary: Header and object files for development using libkrisp%{?compat}
Summary(ko): libkrisp%{?compat} 를 이용하여 개발하기 위한 header 파일과 목적 파일들
Requires: libkrisp%{?compat}
Group: System Environment/Libraries
%description devel
The libkrisp%{?compat}-devel package contains the header and object files necessary
for developing programs which use the libkrisp%{?compat} libraries.
%description devel -l ko
libkrisp%{?compat}-devel 패키지는 libkrisp%{?compat} 라이브러리를 이용하여 개발을 하기 위한 목적
코드와 헤더 파일들을 포함하고 있다.
%prep
rm -rf %{buildroot}
%setup -q -n libkrisp-%{version}
%build
%configure %{?compat:--with-compat=%{compat}}
# remove rpath
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
%{__make} %{?_smp_mflags}
#
# create database
#
#pushd db
#[ -f krisp.dat ] && %{__rm} -f krisp.dat
#sqlite3 krisp.dat < table
#popd
%install
%{__make} DESTDIR=%{buildroot} install
%clean
%{__rm} -rf %{buildroot}
%post
/sbin/ldconfig
%postun
/sbin/ldconfig
%files
%defattr(0755,root,root)
%doc Changes LICENSE README.md
%{_bindir}/krisplookup%{?compat}
%{_bindir}/krispmkdb%{?compat}
%{_libdir}/libkrisp%{?compat}.so.*
#attr (0644, root, root) %{_datadir}/krisp%{?compat}/*.dat
%{!?compat:%attr(0644,root,root) %{_mandir}/man1/*.1*}
%{!?compat:%attr(0644,root,root) %{_mandir}/ko/man1/*.1*}
%files devel
%defattr(0644,root,root,0755)
%attr(0755,root,root) %{_bindir}/krisp%{?compat}-config
%{_libdir}/*.so
%{_libdir}/*.a
%{_libdir}/*.la
%{_libdir}/pkgconfig/*.pc
%{_includedir}/krisp%{?compat}/*.h
%{!?compat:%{_datadir}/aclocal/*.m4}
%{!?compat:%{_mandir}/man3/*.3*}
%{!?compat:%{_mandir}/ko/man3/*.3*}
%changelog
* @PACKAGE_DATE@ JoungKyun.Kim <http://oops.org> - @PACKAGE_VERSION@-1
- release @PACKAGE_VERSION@