]>
Commit | Line | Data |
---|---|---|
1 | ||
2 | %include /usr/lib/rpm/macros.java | |
3 | ||
4 | %define jarver 1.1.17 | |
5 | ||
6 | Summary: Native Tomcat Connector based on APR | |
7 | Summary(pl.UTF-8): Natywny Connector Tomcata oparty o APR | |
8 | Name: tomcat-native | |
9 | Version: 1.1.20 | |
10 | Release: 2 | |
11 | License: Apache v2 | |
12 | Group: Libraries | |
13 | Source0: http://www.apache.org/dist/tomcat/tomcat-connectors/native/%{version}/source/%{name}-%{version}-src.tar.gz | |
14 | # Source0-md5: fb2b9d073cb6575c2d0020eda266ca0c | |
15 | URL: http://tomcat.apache.org/native-doc | |
16 | BuildRequires: ant | |
17 | BuildRequires: apr-devel | |
18 | BuildRequires: autoconf | |
19 | BuildRequires: automake | |
20 | BuildRequires: jdk | |
21 | BuildRequires: jpackage-utils | |
22 | BuildRequires: libtool | |
23 | BuildRequires: openssl-devel | |
24 | BuildRequires: rpm >= 4.4.9-56 | |
25 | BuildRequires: rpm-javaprov | |
26 | BuildRequires: rpmbuild(macros) >= 1.300 | |
27 | BuildConflicts: java-gcj-compat | |
28 | ExclusiveArch: i586 i686 pentium3 pentium4 athlon %{x8664} | |
29 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
30 | ||
31 | %description | |
32 | Tomcat can use the Apache Portable Runtime to provide superior | |
33 | scalability, performance, and better integration with native server | |
34 | technologies. The Apache Portable Runtime is a highly portable library | |
35 | that is at the heart of Apache HTTP Server 2.x. APR has many uses, | |
36 | including access to advanced IO functionality (such as sendfile, epoll | |
37 | and OpenSSL), OS level functionality (random number generation, system | |
38 | status, etc), and native process handling (shared memory, NT pipes and | |
39 | Unix sockets). | |
40 | ||
41 | These features allows making Tomcat a general purpose webserver, will | |
42 | enable much better integration with other native web technologies, and | |
43 | overall make Java much more viable as a full fledged webserver | |
44 | platform rather than simply a backend focused technology. | |
45 | ||
46 | %description -l pl.UTF-8 | |
47 | Tomcat może wykorzytać Apache Portable Runtime aby zapewnić najwyższą, | |
48 | saklowalność, wydajność i lepszą integrację z natywnymi technologiami | |
49 | serwerowymi. | |
50 | ||
51 | Apache portable Runtime jest wysoce przenośną biblioteką, która jest | |
52 | sercem serwera Apache HTTPD 2.x. APR ma wiele zestosowań, m. in. | |
53 | dostępd do zaawansowanych funkcjonalnośći IO (takich jak sendfile, | |
54 | epoll i OpenSSL), funkcjonalności posiomu systemu operacyjnego | |
55 | (generacja liczb losowych, stan systemu, itp.) i natywną obsługę | |
56 | procesów (współdzielona pamięć, potoki NT i gniazda uniksowe). | |
57 | ||
58 | Te cechy pozwalają na wykorzystanie Tomcata jako sewera www do | |
59 | zastosowań ogólnych, pozwalają na o wiele lepszą integrację z innymi | |
60 | natywnymi technologiami www i w ogólności pozwalają na traktowanie | |
61 | Javy jako zaawansowanej i kompletnej platformy www a nie tylko | |
62 | technologii backendowej. | |
63 | ||
64 | %package devel | |
65 | Summary: Header files for tcnative library | |
66 | Summary(pl.UTF-8): Pliki nagłówwkowe biblioteki tcnative | |
67 | Group: Development/Libraries | |
68 | Requires: %{name} = %{version}-%{release} | |
69 | ||
70 | %description devel | |
71 | Header files for tcnative library. | |
72 | ||
73 | %description devel -l pl.UTF-8 | |
74 | Pliki nagłówkowe biblioteki tcnative. | |
75 | ||
76 | %package static | |
77 | Summary: Static tcnative library | |
78 | Summary(pl.UTF-8): Statyczna biblioteka tcnative | |
79 | Group: Development/Libraries | |
80 | Requires: %{name}-devel = %{version}-%{release} | |
81 | ||
82 | %description static | |
83 | Static tcnative library. | |
84 | ||
85 | %description static -l pl.UTF-8 | |
86 | Statyczna biblioteka tcnative. | |
87 | ||
88 | %prep | |
89 | %setup -q -n %{name}-%{version}-src | |
90 | ||
91 | %build | |
92 | # build java part | |
93 | cd jni | |
94 | %ant clean jar | |
95 | ||
96 | # build native part | |
97 | cd native | |
98 | ./buildconf --with-apr=%{_datadir}/apr | |
99 | %configure \ | |
100 | --with-java-home=%{java_home} \ | |
101 | --with-apr=/usr | |
102 | %{__make} | |
103 | ||
104 | %install | |
105 | rm -rf $RPM_BUILD_ROOT | |
106 | ||
107 | cd jni | |
108 | install -d $RPM_BUILD_ROOT/%{_javadir} | |
109 | install dist/tomcat-native-%{jarver}-dev.jar $RPM_BUILD_ROOT/%{_javadir}/tomcat-native-%{jarver}.jar | |
110 | ln -s tomcat-native-%{jarver}.jar $RPM_BUILD_ROOT/%{_javadir}/tomcat-native.jar | |
111 | ||
112 | cd native | |
113 | %{__make} install \ | |
114 | prefix=%{_prefix} \ | |
115 | DESTDIR=$RPM_BUILD_ROOT | |
116 | ||
117 | # Why Makefile doesn't do that? | |
118 | install -d $RPM_BUILD_ROOT/%{_includedir} | |
119 | install include/*.h $RPM_BUILD_ROOT/%{_includedir} | |
120 | ||
121 | %clean | |
122 | rm -rf $RPM_BUILD_ROOT | |
123 | ||
124 | %post -p /sbin/ldconfig | |
125 | %postun -p /sbin/ldconfig | |
126 | ||
127 | %files | |
128 | %defattr(644,root,root,755) | |
129 | %doc CHANGELOG.txt KEYS README.txt | |
130 | %{_javadir}/%{name}-%{jarver}.jar | |
131 | %{_javadir}/%{name}.jar | |
132 | %attr(755,root,root) %{_libdir}/libtcnative-1.so.*.* | |
133 | %attr(755,root,root) %ghost %{_libdir}/libtcnative-1.so.0 | |
134 | %{_libdir}/libtcnative-1.so | |
135 | ||
136 | %files devel | |
137 | %defattr(644,root,root,755) | |
138 | %{_libdir}/libtcnative-1.la | |
139 | %{_pkgconfigdir}/tcnative-1.pc | |
140 | %{_includedir}/*.h | |
141 | ||
142 | %files static | |
143 | %defattr(644,root,root,755) | |
144 | %{_libdir}/libtcnative-1.a |