/[packages]/cauldron/proftpd/current/SPECS/proftpd.spec
ViewVC logotype

Contents of /cauldron/proftpd/current/SPECS/proftpd.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 404859 - (show annotations) (download)
Sun Mar 24 15:20:47 2013 UTC (11 years ago) by colin
File size: 35040 byte(s)
Add systemd requires and general post/pre fixes (mga#9302)
1 %define _disable_ld_no_undefined 1
2 %define mod_gss_version 1.3.3
3 %define mod_autohost_version 0.4
4 %define mod_case_version 0.7
5 %define mod_time_version 2.2.1
6 %define mod_vroot_version 0.9.2
7
8 Summary: Professional FTP Server
9 Name: proftpd
10 Version: 1.3.4c
11 Release: %mkrel 2
12 License: GPLv2+
13 Group: System/Servers
14 URL: http://proftpd.org/
15 Source0: ftp://ftp.proftpd.org/distrib/source/%{name}-%{version}.tar.gz
16 Source1: proftpd.logrotate
17 Source2: proftpd.xinetd
18 Source3: proftpd.init
19 Source4: proftpd.service
20 Source5: basic.conf
21 Source7: welcome.msg
22 Source32: 32_mod_shaper.conf
23 # http://sourceforge.net/projects/gssmod/
24 Source100: http://prdownloads.sourceforge.net/gssmod/mod_gss-%{mod_gss_version}.tar.gz
25 # from http://www.castaglia.org/proftpd/
26 Source102: http://www.castaglia.org/proftpd/modules/proftpd-mod-autohost-%{mod_autohost_version}.tar.gz
27 Source103: http://www.castaglia.org/proftpd/modules/proftpd-mod-case-%{mod_case_version}.tar.gz
28 Source105: http://www.castaglia.org/proftpd/modules/proftpd-mod-time-%{mod_time_version}.tar.bz2
29 Source108: http://www.castaglia.org/proftpd/modules/proftpd-mod-vroot-%{mod_vroot_version}.tar.gz
30 Source150: %{name}-tmpfiles.conf
31 Source200: anonymous.conf
32 Patch0: proftpd-1.3.4b-mdv-xferstats_logfile_location.diff
33 Patch2: proftpd-1.3.4b-mdv-use-system-auth-instead-of-pam_unix.diff
34 Patch4: proftpd-1.3.4b-mdv-installfix.diff
35 Patch7: proftpd-1.3.4b-mdv-change_pam_name.diff
36 Patch8: proftpd-1.3.4b-mdv-mod_time_fix.diff
37 Patch10: proftpd-1.3.4b-mdv-verbose_tests.diff
38 Patch40: proftpd-1.3.4b-mdv-mod_gss-1.3.0-format_not_a_string_literal_and_no_format_arguments.diff
39 Patch41: proftpd-1.3.4b-mdv-mod_time-format_not_a_string_literal_and_no_format_arguments.diff
40 Patch42: proftpd-1.3.4b-mdv-no_-ldes425.diff
41 Requires: pam >= 0.59
42 Requires: setup
43 Requires(post): systemd >= %{systemd_required_version}
44 Requires(post): rpm-helper
45 Requires(postun): rpm-helper
46 Requires(preun): rpm-helper
47 Requires(pre): rpm-helper
48 BuildRequires: cap-devel
49 BuildRequires: gettext-devel
50 BuildRequires: libacl-devel
51 BuildRequires: libattr-devel
52 BuildRequires: krb5-devel
53 BuildRequires: libtool
54 BuildRequires: libtool-devel
55 BuildRequires: mysql-devel
56 BuildRequires: ncurses-devel
57 BuildRequires: openldap-devel
58 BuildRequires: openssl-devel
59 BuildRequires: pam-devel
60 BuildRequires: pkgconfig
61 BuildRequires: postgresql-libs-devel
62 BuildRequires: sasl-plug-gssapi
63 BuildRequires: sqlite3-devel
64 BuildRequires: tcp_wrappers-devel
65 BuildRequires: zlib-devel
66 BuildRequires: libmemcached-devel >= 0.41
67 BuildRequires: pcre-devel
68 BuildRequires: pcreposix-devel
69 Conflicts: vsftpd
70 Conflicts: wu-ftpd
71 Conflicts: pure-ftpd
72 Conflicts: ncftpd
73 Conflicts: anonftp
74
75 %description
76 ProFTPd is an enhanced FTP server with a focus toward simplicity, security, and
77 ease of configuration. It features a very Apache-like configuration syntax,
78 and a highly customizable server infrastructure, including support for multiple
79 'virtual' FTP servers, anonymous FTP, and permission-based directory
80 visibility.
81
82 This version supports both standalone and xinetd operation.
83
84 %package devel
85 Summary: Development files for ProFTPD
86 Group: Development/C
87
88 %description devel
89 This package contains the development headers for ProFTPD
90
91 %package mod_ctrls_admin
92 Summary: Module implementing admin control handlers
93 Group: System/Servers
94 Requires(post): %{name} >= %{version}-%{release}
95 Requires(preun): %{name} >= %{version}-%{release}
96 Requires: %{name} >= %{version}-%{release}
97
98 %description mod_ctrls_admin
99 This module implements administrative control actions for the ftpdctl program.
100
101 %package mod_ifsession
102 Summary: Module supporting conditional per-user/group/class configuration contexts
103 Group: System/Servers
104 Requires(post): %{name} >= %{version}-%{release}
105 Requires(preun): %{name} >= %{version}-%{release}
106 Requires: %{name} >= %{version}-%{release}
107
108 %description mod_ifsession
109 Module supporting conditional per-user/group/class configuration contexts
110
111 %package mod_ldap
112 Summary: LDAP password lookup module for ProFTPD
113 Group: System/Servers
114 Requires(post): %{name} >= %{version}-%{release}
115 Requires(preun): %{name} >= %{version}-%{release}
116 Requires: %{name} >= %{version}-%{release}
117
118 %description mod_ldap
119 LDAP password lookup module for ProFTPD
120
121 %package mod_quotatab
122 Summary: Module for managing FTP byte/file quotas via centralized tables
123 Group: System/Servers
124 Requires(post): %{name} >= %{version}-%{release}
125 Requires(preun): %{name} >= %{version}-%{release}
126 Requires: %{name} >= %{version}-%{release}
127 Requires: %{name}-mod_quotatab_driver = %{version}-%{release}
128
129 %description mod_quotatab
130 Module for managing FTP byte/file quotas via centralized tables
131
132 %package mod_quotatab_file
133 Summary: Sub-module for managing quota data via file-based tables
134 Group: System/Servers
135 Requires(post): %{name} >= %{version}-%{release}
136 Requires(preun): %{name} >= %{version}-%{release}
137 Requires: %{name}-mod_quotatab = %{version}-%{release}
138 Provides: %{name}-mod_quotatab_driver = %{version}-%{release}
139
140 %description mod_quotatab_file
141 Sub-module for managing quota data via file-based tables
142
143 %package mod_quotatab_ldap
144 Summary: Sub-module for obtaining quota information from an LDAP directory
145 Group: System/Servers
146 Requires(post): %{name} >= %{version}-%{release}
147 Requires(preun): %{name} >= %{version}-%{release}
148 Requires: %{name}-mod_quotatab = %{version}-%{release}
149 Provides: %{name}-mod_quotatab_driver = %{version}-%{release}
150
151 %description mod_quotatab_ldap
152 Sub-module for obtaining quota information from an LDAP directory
153
154 %package mod_quotatab_sql
155 Summary: Sub-module for managing quota data via SQL-based tables
156 Group: System/Servers
157 Requires(post): %{name} >= %{version}-%{release}
158 Requires(preun): %{name} >= %{version}-%{release}
159 Requires: %{name}-mod_quotatab = %{version}-%{release}
160 Provides: %{name}-mod_quotatab_driver = %{version}-%{release}
161
162 %description mod_quotatab_sql
163 Sub-module for managing quota data via SQL-based tables
164
165 %package mod_quotatab_radius
166 Summary: Sub-module for managing quota data via radius
167 Group: System/Servers
168 Requires(post): %{name} >= %{version}-%{release}
169 Requires(preun): %{name} >= %{version}-%{release}
170 Requires: %{name}-mod_quotatab = %{version}-%{release}
171 Provides: %{name}-mod_quotatab_driver = %{version}-%{release}
172
173 %description mod_quotatab_radius
174 Sub-module for managing quota data via radius
175
176 %package mod_radius
177 Summary: Module for RADIUS authentication and accounting
178 Group: System/Servers
179 Requires(post): %{name} >= %{version}-%{release}
180 Requires(preun): %{name} >= %{version}-%{release}
181 Requires: %{name} >= %{version}-%{release}
182
183 %description mod_radius
184 Module for RADIUS authentication and accounting
185
186 %package mod_ratio
187 Summary: Support upload/download ratios
188 Group: System/Servers
189 Requires(post): %{name} >= %{version}-%{release}
190 Requires(preun): %{name} >= %{version}-%{release}
191 Requires: %{name} >= %{version}-%{release}
192
193 %description mod_ratio
194 Support upload/download ratios
195
196 %package mod_rewrite
197 Summary: Module for rewriting FTP commands
198 Group: System/Servers
199 Requires(post): %{name} >= %{version}-%{release}
200 Requires(preun): %{name} >= %{version}-%{release}
201 Requires: %{name} >= %{version}-%{release}
202
203 %description mod_rewrite
204 Module for rewriting FTP commands
205
206 %package mod_site_misc
207 Summary: Module implementing miscellaneous SITE commands
208 Group: System/Servers
209 Requires(post): %{name} >= %{version}-%{release}
210 Requires(preun): %{name} >= %{version}-%{release}
211 Requires: %{name} >= %{version}-%{release}
212
213 %description mod_site_misc
214 Module implementing miscellaneous SITE commands
215
216 %package mod_sql
217 Summary: SQL frontend
218 Group: System/Servers
219 Requires(post): %{name} >= %{version}-%{release}
220 Requires(preun): %{name} >= %{version}-%{release}
221 Requires: %{name} >= %{version}-%{release}
222 Requires: %{name}-mod_sql_driver = %{version}-%{release}
223
224 %description mod_sql
225 SQL frontend
226
227 %package mod_sql_mysql
228 Summary: Support for connecting to MySQL databases
229 Group: System/Servers
230 Requires(post): %{name} >= %{version}-%{release}
231 Requires(preun): %{name} >= %{version}-%{release}
232 Requires: %{name}-mod_sql = %{version}-%{release}
233 Provides: %{name}-mod_sql_driver = %{version}-%{release}
234
235 %description mod_sql_mysql
236 Support for connecting to MySQL databases
237
238 %package mod_sql_postgres
239 Summary: Support for connecting to Postgres databases
240 Group: System/Servers
241 Requires(post): %{name} >= %{version}-%{release}
242 Requires(preun): %{name} >= %{version}-%{release}
243 Requires: %{name}-mod_sql = %{version}-%{release}
244 Provides: %{name}-mod_sql_driver = %{version}-%{release}
245
246 %description mod_sql_postgres
247 Support for connecting to Postgres databases
248
249 %package mod_sql_sqlite
250 Summary: Support for connecting to SQLite3 databases
251 Group: System/Servers
252 Requires(post): %{name} >= %{version}-%{release}
253 Requires(preun): %{name} >= %{version}-%{release}
254 Requires: %{name}-mod_sql = %{version}-%{release}
255 Provides: %{name}-mod_sql_driver = %{version}-%{release}
256
257 %description mod_sql_sqlite
258 Support for connecting to SQLite3 databases
259
260 %package mod_sql_passwd
261 Summary: Various SQL password handlers
262 Group: System/Servers
263 Requires(post): %{name} >= %{version}-%{release}
264 Requires(preun): %{name} >= %{version}-%{release}
265 Requires: %{name}-mod_sql = %{version}-%{release}
266 Provides: %{name}-mod_sql_driver = %{version}-%{release}
267
268 %description mod_sql_passwd
269 Various SQL password handlers
270
271 %package mod_tls
272 Summary: An RFC2228 SSL/TLS module for ProFTPD
273 Group: System/Servers
274 Requires(post): %{name} >= %{version}-%{release}
275 Requires(preun): %{name} >= %{version}-%{release}
276 Requires: %{name} >= %{version}-%{release}
277
278 %description mod_tls
279 An RFC2228 SSL/TLS module for ProFTPD
280
281 %package mod_tls_shmcache
282 Summary: A module which provides a shared SSL session cache using SysV shared memory
283 Group: System/Servers
284 Requires(post): %{name} >= %{version}-%{release}
285 Requires(preun): %{name} >= %{version}-%{release}
286 Requires: %{name} >= %{version}-%{release}
287 Requires: %{name}-mod_tls = %{version}-%{release}
288
289 %description mod_tls_shmcache
290 This submodule provides a SysV shared memory-based implementation of an
291 external SSL session cache for use by the mod_tls module's TLSSessionCache
292 directive.
293
294 %package mod_tls_memcache
295 Summary: A module which provides a shared SSL session cache using memcached servers
296 Group: System/Servers
297 Requires(post): %{name} >= %{version}-%{release}
298 Requires(preun): %{name} >= %{version}-%{release}
299 Requires: %{name} >= %{version}-%{release}
300 Requires: %{name}-mod_tls = %{version}-%{release}
301 Suggests: memcached
302
303 %description mod_tls_memcache
304 This submodule a memcached-based implementation of an external SSL session
305 cache for use by the mod_tls module's TLSSessionCache directive.
306
307 %package mod_autohost
308 Summary: An autohost module for ProFTPD
309 Group: System/Servers
310 Requires(post): %{name} >= %{version}-%{release}
311 Requires(preun): %{name} >= %{version}-%{release}
312 Requires: %{name} >= %{version}-%{release}
313
314 %description mod_autohost
315 For sites that run a large number of <VirtualHost>s for proftpd, it can be
316 cumbersome to configure them all in the proftpd.conf file. Adding or removing
317 virtual server configurations require restarting the daemon, as do changes to
318 one of the server configurations. The daemon also consumes memory for each
319 server configuration, and the memory footprint for the daemon process can grow
320 large for large numbers of servers.
321
322 The mod_autohost module allows for server configurations to be configured in
323 individual files, and for those configuration to be used in an "on demand"
324 fashion. Rather than loading the configurations into memory when the daemon
325 starts up, the daemon will check the IP address and port being contacted by a
326 connecting client, check in the filesystem for a mod_autohost configuration
327 file for that address/port, dynamically parse the configuration, and insert
328 the configuration into the session's process space. Thus changes to the
329 configuration are seen whenever a client connects, without requiring a daemon
330 restart. The memory footprint is reduced because proftpd, via mod_autohost,
331 only reads and uses the needed configuration.
332
333 %package mod_case
334 Summary: Makes ProFTPD case insensitive
335 Group: System/Servers
336 Requires(post): %{name} >= %{version}-%{release}
337 Requires(preun): %{name} >= %{version}-%{release}
338 Requires: %{name} >= %{version}-%{release}
339
340 %description mod_case
341 The mod_case module is designed to help ProFTPD be case-insensitive, for those
342 sites that may need it (e.g. those that are migrating from a Windows
343 environment or have mounted Windows filesystems).
344
345 mod_case works by performing two checks on the filename used in FTP commands.
346 First, mod_case will scan the directory to see if there is already a file whose
347 name exactly matches the given filename. If not, mod_case will scan the
348 directory again, this time looking for case-insensitive matches.
349
350 %package mod_gss
351 Summary: A Kerberos 5 GSS module for ProFTPD
352 Group: System/Servers
353 Requires(post): %{name} >= %{version}-%{release}
354 Requires(preun): %{name} >= %{version}-%{release}
355 Requires: %{name} >= %{version}-%{release}
356
357 %description mod_gss
358 A Kerberos 5 GSS module for ProFTPD
359
360 %package mod_load
361 Summary: A module that determines average load for ProFTPD
362 Group: System/Servers
363 Requires(post): %{name} >= %{version}-%{release}
364 Requires(preun): %{name} >= %{version}-%{release}
365 Requires: %{name} >= %{version}-%{release}
366
367 %description mod_load
368 The code for determining load average on a given system is hairy, to say the
369 least. Unfortunately, it is necessary to do it this way, as there is no
370 standard method for extracting such information from the kernel. This module
371 uses code from GNU's make application, which should function properly. If not,
372 please contact the author as soon as possible.
373
374 %package mod_shaper
375 Summary: A shaping module for ProFTPD
376 Group: System/Servers
377 Requires(post): %{name} >= %{version}-%{release}
378 Requires(preun): %{name} >= %{version}-%{release}
379 Requires: %{name} >= %{version}-%{release}
380
381 %description mod_shaper
382 The mod_shaper module is designed to split overall rates, both download and
383 upload, for the proftpd daemon among all connected FTP clients, shaping each
384 session to use only a portion of the overall rate. mod_shaper shapes both
385 transmitted traffic, e.g. bits being downloaded via the RETR command, and
386 received traffic, e.g. bits being uploaded via the APPE, STOR, and STOU
387 commands.
388
389 %package mod_time
390 Summary: Limits acces based on the time of day and/or the day of the week
391 Group: System/Servers
392 Requires(post): %{name} >= %{version}-%{release}
393 Requires(preun): %{name} >= %{version}-%{release}
394 Requires: %{name} >= %{version}-%{release}
395
396 %description mod_time
397 This module is designed to allow for limiting FTP commands based on the time of
398 day and/or the day of the week. A more detailed explanation of the usage of
399 this module follows the directive explanations.
400
401 %package mod_wrap
402 Summary: Provides tcpwrapper-like access control rules for ProFTPD
403 Group: System/Servers
404 Requires(post): %{name} >= %{version}-%{release}
405 Requires(preun): %{name} >= %{version}-%{release}
406 Requires: %{name} >= %{version}-%{release}
407 Requires: %{name}-mod_wrap_driver = %{version}-%{release}
408 Requires: tcp_wrappers
409
410 %description mod_wrap
411 The mod_wrap package allows the proftpd daemon to provide tcpwrapper-like
412 access control rules while running in standalone mode. It also allows for those
413 access rules to be stored in various formats, such as files (e.g.
414 /etc/hosts.allow and /etc/hosts.deny) or in SQL tables.
415
416 The most current version of mod_wrap's submodules supports storage of access
417 table information in various formats:
418
419 o mod_wrap_file for file-based access tables
420 o mod_wrap_sql for SQL-based access tables
421
422 %package mod_wrap_file
423 Summary: A file-specific driver for the mod_wrap module for ProFTPD
424 Group: System/Servers
425 Requires(post): %{name} >= %{version}-%{release}
426 Requires(preun): %{name} >= %{version}-%{release}
427 Requires: %{name} >= %{version}-%{release}
428 Provides: %{name}-mod_wrap_driver = %{version}-%{release}
429
430 %description mod_wrap_file
431 This submodule provides the file-specific "driver" for storing IP/DNS-based
432 access control information in files.
433
434 %package mod_wrap_sql
435 Summary: A SQL database driver for the mod_wrap module for ProFTPD
436 Group: System/Servers
437 Requires(post): %{name} >= %{version}-%{release}
438 Requires(preun): %{name} >= %{version}-%{release}
439 Requires: %{name} >= %{version}-%{release}
440 Provides: %{name}-mod_wrap_driver = %{version}-%{release}
441
442 %description mod_wrap_sql
443 This submodule provides the SQL database "driver" for storing IP/DNS-based
444 access control information in SQL tables.
445
446 %package mod_ban
447 Summary: Adds dynamic "ban" lists to ProFTPD
448 Group: System/Servers
449 Requires(post): %{name} >= %{version}-%{release}
450 Requires(preun): %{name} >= %{version}-%{release}
451 Requires: %{name} >= %{version}-%{release}
452
453 %description mod_ban
454 The mod_ban module is designed to add dynamic "ban" lists to proftpd. A ban
455 prevents the banned user, host, or class from logging in to the server; it does
456 not prevent the banned user, host, or class from connecting to the server.
457 mod_ban is not a firewall. The module also provides automatic bans that are
458 triggered based on configurable criteria.
459
460 %package mod_vroot
461 Summary: Adds virtual chroot capability to ProFTPD
462 Group: System/Servers
463 Requires(post): %{name} >= %{version}-%{release}
464 Requires(preun): %{name} >= %{version}-%{release}
465 Requires: %{name} >= %{version}-%{release}
466
467 %description mod_vroot
468 The purpose of this module to is to implement a virtual chroot capability that
469 does not require root privileges. The mod_vroot module provides this capability
470 by using ProFTPD's FS API, available as of 1.2.8rc1.
471
472 %package mod_sftp
473 Summary: Implements the SSH2 protocol and its SFTP subsystem for ProFTPD
474 Group: System/Servers
475 Requires(post): %{name} >= %{version}-%{release}
476 Requires(preun): %{name} >= %{version}-%{release}
477 Requires: %{name} >= %{version}-%{release}
478
479 %description mod_sftp
480 The mod_sftp module implements the SSH2 protocol and its SFTP subsystem, for
481 secure file transfer over an SSH2 connection. The mod_sftp module supports:
482
483 o Public key authentication
484 o Password authentication (e.g. user authentication via mod_sql, mod_ldap,
485 mod_auth_file, mod_auth_unix, mod_auth_pam)
486 o SCP support
487 o Quotas (via the mod_quotatab module)
488 o FIPS support (see Usage section)
489 o Throttled transfers (via TransferRate, and/or the mod_shaper module)
490 o Blacklisted public keys
491 o Configurable traffic analysis protection
492 o Passphrase-protected host keys
493
494 %package mod_sftp_pam
495 Summary: A module which provides an SSH2 "keyboard-interactive" driver using PAM
496 Group: System/Servers
497 Requires(post): %{name} >= %{version}-%{release}
498 Requires(preun): %{name} >= %{version}-%{release}
499 Requires: %{name} >= %{version}-%{release}
500 Requires: %{name}-mod_sftp >= %{version}-%{release}
501
502 %description mod_sftp_pam
503 The mod_sftp_pam module provides support for the "SSH Keyboard-Interactive
504 Authentication" RFC (RFC4256).
505
506 %package mod_sftp_sql
507 Summary: SQL backend module for retrieving authorized keys
508 Group: System/Servers
509 Requires(post): %{name} >= %{version}-%{release}
510 Requires(preun): %{name} >= %{version}-%{release}
511 Requires: %{name} >= %{version}-%{release}
512 Requires: %{name}-mod_sftp >= %{version}-%{release}
513 Requires: %{name}-mod_sql >= %{version}-%{release}
514
515 %description mod_sftp_sql
516 The mod_sftp module for ProFTPD can support different storage formats for its
517 user- and host-based authorized keys. By default, the mod_sftp module supports
518 storing authorized keys in flats. This mod_sftp_sql module allows for
519 authorized SSH keys to be stored in SQL tables.
520
521 %package mod_memcache
522 Summary: A module for managing memcache data
523 Group: System/Servers
524 Requires(post): %{name} >= %{version}-%{release}
525 Requires(preun): %{name} >= %{version}-%{release}
526 Requires: %{name} >= %{version}-%{release}
527
528 %description mod_memcache
529 The mod_memcache module enables ProFTPD support for caching data in memcached
530 servers, using the libmemcached client library.
531
532 %prep
533
534 %setup -q -n %{name}-%{version} -a100 -a102 -a103 -a105 -a108
535
536 %patch0 -p0 -b .logfile_location
537 %patch2 -p0 -b .pam
538 %patch4 -p1 -b .installfix
539 %patch7 -p0 -b .change_pam_name
540 %patch8 -p0 -b .mod_time_fix
541 %patch10 -p0 -b .verbose_tests
542
543 %patch40 -p0 -b .format_not_a_string_literal_and_no_format_arguments
544 %patch41 -p0 -b .format_not_a_string_literal_and_no_format_arguments
545 %patch42 -p1 -b .no_-ldes425
546
547 # ours config
548 mkdir -p %{_vendor}
549 install -m0644 %{SOURCE1} %{_vendor}/proftpd.logrotate
550 install -m0644 %{SOURCE2} %{_vendor}/proftpd.xinetd
551 install -m0644 %{SOURCE3} %{_vendor}/proftpd.init
552 install -m0644 %{SOURCE4} %{_vendor}/proftpd.service
553 install -m0644 %{SOURCE5} %{_vendor}/basic.conf
554 install -m0644 %{SOURCE7} %{_vendor}/welcome.msg
555 install -m0644 %{SOURCE32} %{_vendor}/32_mod_shaper.conf
556
557 # lib64 fix
558 perl -pi -e "s|/usr/lib|%{_libdir}|g" %{_vendor}/basic.conf
559
560 # fix includes, instead of a patch
561 perl -pi -e "s|\<mysql\.h\>|\<mysql\/mysql\.h\>|g" contrib/mod_sql_mysql.c
562
563
564 %build
565
566 %serverbuild
567
568 export CFLAGS="$CFLAGS -DLDAP_DEPRECATED -DUSE_LDAP_TLS -DHAVE_OPENSSL"
569 export LIBS="-L%{_libdir} -lattr"
570
571 pushd mod_gss-%{mod_gss_version}
572 perl -pi -e "s|<gssapi.h>|<gssapi/gssapi.h>|" configure*
573 perl -pi -e "s|NULL,code|kc,code|" *.in
574
575 %configure2_5x --enable-mit
576
577 # Workaround a missing dcl in kerberos...
578 cat >> mod_gss.h <<EOF
579 #ifndef GSS_C_AF_INET6
580 #define GSS_C_AF_INET6 24
581 #endif
582 EOF
583 popd
584
585 pushd contrib/mod_load
586 %configure2_5x
587 popd
588
589 pushd contrib/mod_wrap2
590 %configure2_5x
591 popd
592
593 # put extra modules in place
594 for i in `find mod_* -type f -name "*.c"` `find mod_* -type f -name "*.h"`; do
595 cp $i contrib/
596 done
597
598
599 %configure2_5x \
600 --libexecdir=%{_libdir}/%{name} \
601 --enable-auth-pam \
602 --enable-cap \
603 --disable-facl \
604 --enable-dso \
605 --enable-nls \
606 --enable-openssl \
607 --with-lastlog=/var/log/lastlog \
608 --enable-ipv6 \
609 --enable-shadow \
610 --enable-ctrls \
611 --with-shared="mod_ratio:mod_tls:mod_tls_shmcache:mod_radius:mod_ldap:mod_sql:mod_sql_mysql:mod_sql_postgres:mod_sql_sqlite:mod_sql_passwd:mod_rewrite:mod_gss:mod_load:mod_ctrls_admin:mod_quotatab:mod_quotatab_file:mod_quotatab_ldap:mod_quotatab_sql:mod_quotatab_radius:mod_site_misc:mod_wrap2:mod_wrap2_file:mod_wrap2_sql:mod_autohost:mod_case:mod_shaper:mod_ban:mod_vroot:mod_sftp:mod_sftp_pam:mod_sftp_sql:mod_time:mod_ifsession:mod_memcache:mod_tls_memcache" \
612 --with-modules="mod_readme:mod_auth_pam" \
613 --disable-strip \
614 --enable-pcre
615
616
617 # libcap hack
618 perl -pi -e "s|/lib/libcap|/blabla|g" Make.rules
619 echo "#define HAVE_LINUX_CAPABILITY_H 1" >> config.h
620
621 %make
622
623
624 %install
625 rm -rf %{buildroot}
626
627 install -d %{buildroot}%{_initrddir}
628 install -d %{buildroot}%{_libdir}/%{name}
629 install -d %{buildroot}%{_sysconfdir}/logrotate.d
630 install -d %{buildroot}%{_sysconfdir}/%{name}.d
631 install -d %{buildroot}%{_sysconfdir}/pam.d
632 install -d %{buildroot}%{_sysconfdir}/xinetd.d
633 install -d %{buildroot}%{_localstatedir}/ftp/pub
634 install -d %{buildroot}%{_localstatedir}/log/%{name}
635 install -D -p -m 0644 %{SOURCE150} %{buildroot}%{_tmpfilesdir}/%{name}.conf
636
637 %makeinstall \
638 LIBEXECDIR=%{buildroot}%{_libdir}/%{name} \
639 SHARED_MODULE_DIRS="" \
640 pkgconfigdir=%{buildroot}%{_libdir}/pkgconfig
641
642 # fix borked pkgconfig file
643 perl -pi -e "s|^prefix.*|prefix=%{_prefix}|g" %{buildroot}%{_libdir}/pkgconfig/*.pc
644 perl -pi -e "s|/lib/|/%{_lib}/|g" %{buildroot}%{_libdir}/pkgconfig/*.pc
645
646 %makeinstall -C contrib/mod_wrap2 LIBEXECDIR=%{buildroot}%{_libdir}/%{name}
647 %makeinstall -C contrib/mod_load LIBEXECDIR=%{buildroot}%{_libdir}/%{name}
648 %makeinstall -C contrib/mod_sftp LIBEXECDIR=%{buildroot}%{_libdir}/%{name}
649
650 install -m0644 contrib/dist/rpm/ftp.pamd %{buildroot}%{_sysconfdir}/pam.d/%{name}
651 install -m0755 contrib/xferstats.holger-preiss %{buildroot}%{_sbindir}
652
653 install -m0644 %{_vendor}/proftpd.logrotate %{buildroot}%{_sysconfdir}/logrotate.d/%{name}
654 install -m0644 %{_vendor}/proftpd.xinetd %{buildroot}%{_sysconfdir}/xinetd.d/%{name}-xinetd
655 install -m0755 %{_vendor}/proftpd.init %{buildroot}%{_initrddir}/%{name}
656 install -m0644 %{_vendor}/basic.conf %{buildroot}%{_sysconfdir}/%{name}.conf
657 install -m0644 %{_vendor}/welcome.msg %{buildroot}%{_localstatedir}/ftp/pub/welcome.msg
658
659 install -m0644 %{SOURCE200} %{buildroot}%{_sysconfdir}/proftpd-anonymous.conf
660
661 ln -snf %{name} %{buildroot}%{_sbindir}/in.%{name}
662 ln -snf %{name} %{buildroot}%{_sbindir}/in.ftpd
663
664 # config
665 echo "LoadModule mod_ctrls_admin.c" > %{buildroot}%{_sysconfdir}/%{name}.d/10_mod_ctrls_admin.conf
666 echo "LoadModule mod_tls.c" > %{buildroot}%{_sysconfdir}/%{name}.d/11_mod_tls.conf
667 echo "LoadModule mod_tls_shmcache.c" > %{buildroot}%{_sysconfdir}/%{name}.d/12_mod_tls_shmcache.conf
668 echo "LoadModule mod_sql.c" > %{buildroot}%{_sysconfdir}/%{name}.d/12_mod_sql.conf
669 echo "LoadModule mod_ldap.c" > %{buildroot}%{_sysconfdir}/%{name}.d/13_mod_ldap.conf
670 echo "LoadModule mod_sql_mysql.c" > %{buildroot}%{_sysconfdir}/%{name}.d/14_mod_sql_mysql.conf
671 echo "LoadModule mod_sql_postgres.c" > %{buildroot}%{_sysconfdir}/%{name}.d/15_mod_sql_postgres.conf
672 echo "LoadModule mod_sql_sqlite.c" > %{buildroot}%{_sysconfdir}/%{name}.d/16_mod_sql_sqlite.conf
673 echo "LoadModule mod_sql_passwd.c" > %{buildroot}%{_sysconfdir}/%{name}.d/17_mod_sql_passwd.conf
674 echo "LoadModule mod_quotatab.c" > %{buildroot}%{_sysconfdir}/%{name}.d/16_mod_quotatab.conf
675 echo "LoadModule mod_quotatab_file.c" > %{buildroot}%{_sysconfdir}/%{name}.d/17_mod_quotatab_file.conf
676 echo "LoadModule mod_quotatab_ldap.c" > %{buildroot}%{_sysconfdir}/%{name}.d/18_mod_quotatab_ldap.conf
677 echo "LoadModule mod_quotatab_sql.c" > %{buildroot}%{_sysconfdir}/%{name}.d/19_mod_quotatab_sql.conf
678 echo "LoadModule mod_quotatab_radius.c" > %{buildroot}%{_sysconfdir}/%{name}.d/20_mod_quotatab_radius.conf
679 echo "LoadModule mod_radius.c" > %{buildroot}%{_sysconfdir}/%{name}.d/20_mod_radius.conf
680 echo "LoadModule mod_wrap2.c" > %{buildroot}%{_sysconfdir}/%{name}.d/21_mod_wrap2.conf
681 echo "LoadModule mod_wrap2_file.c" > %{buildroot}%{_sysconfdir}/%{name}.d/22_mod_wrap2_file.conf
682 echo "LoadModule mod_wrap2_sql.c" > %{buildroot}%{_sysconfdir}/%{name}.d/23_mod_wrap2_sql.conf
683 echo "LoadModule mod_rewrite.c" > %{buildroot}%{_sysconfdir}/%{name}.d/24_mod_rewrite.conf
684 echo "LoadModule mod_ratio.c" > %{buildroot}%{_sysconfdir}/%{name}.d/25_mod_ratio.conf
685 echo "LoadModule mod_gss.c" > %{buildroot}%{_sysconfdir}/%{name}.d/26_mod_gss.conf
686 echo "LoadModule mod_autohost.c" > %{buildroot}%{_sysconfdir}/%{name}.d/27_mod_autohost.conf
687 echo "LoadModule mod_case.c" > %{buildroot}%{_sysconfdir}/%{name}.d/28_mod_case.conf
688 echo "LoadModule mod_load.c" > %{buildroot}%{_sysconfdir}/%{name}.d/31_mod_load.conf
689 install -m0644 %{_vendor}/32_mod_shaper.conf %{buildroot}%{_sysconfdir}/%{name}.d/32_mod_shaper.conf
690 echo "LoadModule mod_site_misc.c" > %{buildroot}%{_sysconfdir}/%{name}.d/33_mod_site_misc.conf
691 echo "LoadModule mod_time.c" > %{buildroot}%{_sysconfdir}/%{name}.d/34_mod_time.conf
692 echo "LoadModule mod_ban.c" > %{buildroot}%{_sysconfdir}/%{name}.d/35_mod_ban.conf
693 echo "LoadModule mod_vroot.c" > %{buildroot}%{_sysconfdir}/%{name}.d/36_mod_vroot.conf
694 echo "LoadModule mod_sftp.c" > %{buildroot}%{_sysconfdir}/%{name}.d/37_mod_sftp.conf
695 echo "LoadModule mod_sftp_pam.c" > %{buildroot}%{_sysconfdir}/%{name}.d/38_mod_sftp_pam.conf
696 echo "LoadModule mod_sftp_sql.c" > %{buildroot}%{_sysconfdir}/%{name}.d/39_mod_sftp_sql.conf
697 echo "LoadModule mod_memcache.c" > %{buildroot}%{_sysconfdir}/%{name}.d/40_mod_memcache.conf
698 echo "LoadModule mod_tls_memcache.c" > %{buildroot}%{_sysconfdir}/%{name}.d/41_mod_tls_memcache.conf
699
700 cat > %{buildroot}%{_sysconfdir}/%{name}.d/99_mod_ifsession.conf << EOF
701 # keep this module the last one
702 LoadModule mod_ifsession.c
703 EOF
704
705 # automatic reloading for new plugins
706 install -d %buildroot%{_var}/lib/rpm/filetriggers
707 cat > %buildroot%{_var}/lib/rpm/filetriggers/%{name}.filter << EOF
708 ^.%{_sysconfdir}/proftpd.d/.*\.conf$
709 EOF
710 cat > %buildroot%{_var}/lib/rpm/filetriggers/%{name}.script << EOF
711 #!/bin/sh
712 systemctl try-restart proftpd.service
713 EOF
714 chmod 755 %buildroot%{_var}/lib/rpm/filetriggers/%{name}.script
715
716
717 %find_lang %{name}
718
719 # cleanup
720 rm -f %{buildroot}%{_libdir}/%{name}/*.{a,la}
721 rm -f contrib/README.mod_sql contrib/README.linux-privs
722
723 cat > %{buildroot}%{_sysconfdir}/ftpusers << EOF
724 root
725 bin
726 daemon
727 adm
728 lp
729 sync
730 shutdown
731 halt
732 mail
733 news
734 uucp
735 operator
736 games
737 nobody
738 EOF
739
740 %post
741 %_tmpfilescreate %{name}
742 %_post_service %{name}
743
744 %pre
745 %_pre_useradd ftp /var/ftp /bin/false
746
747 %postun
748 %_postun_userdel ftp
749
750 %preun
751 %_preun_service %{name}
752
753 %files -f %{name}.lang
754 %doc README* INSTALL NEWS CREDITS COPYING doc/*
755 %doc sample-configurations/*
756 %dir %{_sysconfdir}/proftpd.d
757 %config(noreplace) %{_sysconfdir}/%{name}.conf
758 %config(noreplace) %{_sysconfdir}/%{name}-anonymous.conf
759 %config(noreplace) %{_sysconfdir}/pam.d/%{name}
760 %config(noreplace) %{_sysconfdir}/xinetd.d/%{name}-xinetd
761 %config(noreplace) %{_sysconfdir}/logrotate.d/%{name}
762 %config(noreplace) %{_sysconfdir}/ftpusers
763 %{_initrddir}/%{name}
764 %{_sbindir}/%{name}
765 %{_sbindir}/ftpscrub
766 %{_sbindir}/ftpshut
767 %{_sbindir}/in.ftpd
768 %{_sbindir}/in.%{name}
769 %{_sbindir}/xferstats.holger-preiss
770 %{_bindir}/ftpasswd
771 %{_bindir}/ftpcount
772 %{_bindir}/ftpdctl
773 %{_bindir}/ftpmail
774 %{_bindir}/ftpquota
775 %{_bindir}/ftptop
776 %{_bindir}/ftpwho
777 %{_bindir}/prxs
778 %dir %{_libdir}/%{name}
779 %dir %{_localstatedir}/ftp
780 %dir %{_localstatedir}/ftp/pub
781 %config(noreplace) %{_localstatedir}/ftp/pub/welcome.msg
782 %{_tmpfilesdir}/%{name}.conf
783 %dir %{_localstatedir}/log/%{name}
784 %{_mandir}/man*/*
785 %{_var}/lib/rpm/filetriggers/proftpd.*
786
787 %files devel
788 %doc ChangeLog
789 %dir %{_includedir}/%{name}
790 %{_includedir}/%{name}/*.h
791 %{_libdir}/pkgconfig/*.pc
792
793 %files mod_ctrls_admin
794 %doc doc/contrib/mod_ctrls_admin.html
795 %config(noreplace) %{_sysconfdir}/%{name}.d/10_mod_ctrls_admin.conf
796 %{_libdir}/%{name}/mod_ctrls_admin.so
797
798 %files mod_ifsession
799 %doc doc/contrib/mod_ifsession.html
800 %config(noreplace) %{_sysconfdir}/%{name}.d/99_mod_ifsession.conf
801 %{_libdir}/%{name}/mod_ifsession.so
802
803 %files mod_ldap
804 %config(noreplace) %{_sysconfdir}/%{name}.d/13_mod_ldap.conf
805 %{_libdir}/%{name}/mod_ldap.so
806
807 %files mod_quotatab
808 %doc doc/contrib/mod_quotatab.html
809 %config(noreplace) %{_sysconfdir}/%{name}.d/16_mod_quotatab.conf
810 %{_libdir}/%{name}/mod_quotatab.so
811
812 %files mod_quotatab_file
813 %doc doc/contrib/mod_quotatab_file.html
814 %config(noreplace) %{_sysconfdir}/%{name}.d/17_mod_quotatab_file.conf
815 %{_libdir}/%{name}/mod_quotatab_file.so
816
817 %files mod_quotatab_ldap
818 %doc doc/contrib/mod_quotatab_ldap.html
819 %config(noreplace) %{_sysconfdir}/%{name}.d/18_mod_quotatab_ldap.conf
820 %{_libdir}/%{name}/mod_quotatab_ldap.so
821
822 %files mod_quotatab_sql
823 %doc doc/contrib/mod_quotatab_sql.html
824 %config(noreplace) %{_sysconfdir}/%{name}.d/19_mod_quotatab_sql.conf
825 %{_libdir}/%{name}/mod_quotatab_sql.so
826
827 %files mod_quotatab_radius
828 %doc doc/contrib/mod_quotatab_radius.html
829 %config(noreplace) %{_sysconfdir}/%{name}.d/20_mod_quotatab_radius.conf
830 %{_libdir}/%{name}/mod_quotatab_radius.so
831
832 %files mod_radius
833 %doc doc/contrib/mod_radius.html
834 %config(noreplace) %{_sysconfdir}/%{name}.d/20_mod_radius.conf
835 %{_libdir}/%{name}/mod_radius.so
836
837 %files mod_ratio
838 %doc contrib/README.ratio
839 %config(noreplace) %{_sysconfdir}/%{name}.d/25_mod_ratio.conf
840 %{_libdir}/%{name}/mod_ratio.so
841
842 %files mod_rewrite
843 %doc doc/contrib/mod_rewrite.html
844 %config(noreplace) %{_sysconfdir}/%{name}.d/24_mod_rewrite.conf
845 %{_libdir}/%{name}/mod_rewrite.so
846
847 %files mod_site_misc
848 %doc doc/contrib/mod_site_misc.html
849 %config(noreplace) %{_sysconfdir}/%{name}.d/33_mod_site_misc.conf
850 %{_libdir}/%{name}/mod_site_misc.so
851
852 %files mod_sql
853 %doc doc/contrib/mod_sql.html
854 %config(noreplace) %{_sysconfdir}/%{name}.d/12_mod_sql.conf
855 %{_libdir}/%{name}/mod_sql.so
856
857 %files mod_sql_mysql
858 %config(noreplace) %{_sysconfdir}/%{name}.d/14_mod_sql_mysql.conf
859 %{_libdir}/%{name}/mod_sql_mysql.so
860
861 %files mod_sql_postgres
862 %config(noreplace) %{_sysconfdir}/%{name}.d/15_mod_sql_postgres.conf
863 %{_libdir}/%{name}/mod_sql_postgres.so
864
865 %files mod_sql_sqlite
866 %config(noreplace) %{_sysconfdir}/%{name}.d/16_mod_sql_sqlite.conf
867 %{_libdir}/%{name}/mod_sql_sqlite.so
868
869 %files mod_sql_passwd
870 %config(noreplace) %{_sysconfdir}/%{name}.d/17_mod_sql_passwd.conf
871 %{_libdir}/%{name}/mod_sql_passwd.so
872
873 %files mod_tls
874 %doc doc/contrib/mod_tls.html
875 %config(noreplace) %{_sysconfdir}/%{name}.d/11_mod_tls.conf
876 %{_libdir}/%{name}/mod_tls.so
877
878 %files mod_tls_shmcache
879 %doc doc/contrib/mod_tls_shmcache.html
880 %config(noreplace) %{_sysconfdir}/%{name}.d/12_mod_tls_shmcache.conf
881 %{_libdir}/%{name}/mod_tls_shmcache.so
882
883 %files mod_tls_memcache
884 %doc doc/contrib/mod_tls_memcache.html
885 %config(noreplace) %{_sysconfdir}/%{name}.d/41_mod_tls_memcache.conf
886 %{_libdir}/%{name}/mod_tls_memcache.so
887
888 %files mod_autohost
889 %doc mod_autohost/mod_autohost.html
890 %config(noreplace) %{_sysconfdir}/%{name}.d/27_mod_autohost.conf
891 %{_libdir}/%{name}/mod_autohost.so
892
893 %files mod_case
894 %doc mod_case/mod_case.html
895 %config(noreplace) %{_sysconfdir}/%{name}.d/28_mod_case.conf
896 %{_libdir}/%{name}/mod_case.so
897
898 %files mod_gss
899 %doc mod_gss-*/COPYING mod_gss-*/mod_gss.html mod_gss-*/README.mod_gss mod_gss-*/rfc1509.txt mod_gss-*/rfc2228.txt
900 %config(noreplace) %{_sysconfdir}/%{name}.d/26_mod_gss.conf
901 %{_libdir}/%{name}/mod_gss.so
902
903 %files mod_load
904 %doc doc/contrib/mod_load.html
905 %config(noreplace) %{_sysconfdir}/%{name}.d/31_mod_load.conf
906 %{_libdir}/%{name}/mod_load.so
907
908 %files mod_shaper
909 %doc doc/contrib/mod_shaper.html
910 %config(noreplace) %{_sysconfdir}/%{name}.d/32_mod_shaper.conf
911 %{_libdir}/%{name}/mod_shaper.so
912
913 %files mod_time
914 %doc mod_time/README mod_time/mod_time.html
915 %config(noreplace) %{_sysconfdir}/%{name}.d/34_mod_time.conf
916 %{_libdir}/%{name}/mod_time.so
917
918 %files mod_wrap
919 %doc doc/contrib/mod_wrap2.html
920 %config(noreplace) %{_sysconfdir}/%{name}.d/21_mod_wrap2.conf
921 %{_libdir}/%{name}/mod_wrap2.so
922
923 %files mod_wrap_file
924 %doc doc/contrib/mod_wrap2_file.html
925 %config(noreplace) %{_sysconfdir}/%{name}.d/22_mod_wrap2_file.conf
926 %{_libdir}/%{name}/mod_wrap2_file.so
927
928 %files mod_wrap_sql
929 %doc doc/contrib/mod_wrap2_sql.html
930 %config(noreplace) %{_sysconfdir}/%{name}.d/23_mod_wrap2_sql.conf
931 %{_libdir}/%{name}/mod_wrap2_sql.so
932
933 %files mod_ban
934 %doc doc/contrib/mod_ban.html
935 %config(noreplace) %{_sysconfdir}/%{name}.d/35_mod_ban.conf
936 %{_libdir}/%{name}/mod_ban.so
937
938 %files mod_vroot
939 %doc mod_vroot/mod_vroot.html
940 %config(noreplace) %{_sysconfdir}/%{name}.d/36_mod_vroot.conf
941 %{_libdir}/%{name}/mod_vroot.so
942
943 %files mod_sftp
944 %doc doc/contrib/mod_sftp.html
945 %config(noreplace) %{_sysconfdir}/blacklist.dat
946 %config(noreplace) %{_sysconfdir}/dhparams.pem
947 %config(noreplace) %{_sysconfdir}/%{name}.d/37_mod_sftp.conf
948 %{_libdir}/%{name}/mod_sftp.so
949
950 %files mod_sftp_pam
951 %doc doc/contrib/mod_sftp_pam.html
952 %config(noreplace) %{_sysconfdir}/%{name}.d/38_mod_sftp_pam.conf
953 %{_libdir}/%{name}/mod_sftp_pam.so
954
955 %files mod_sftp_sql
956 %doc doc/contrib/mod_sftp_sql.html
957 %config(noreplace) %{_sysconfdir}/%{name}.d/39_mod_sftp_sql.conf
958 %{_libdir}/%{name}/mod_sftp_sql.so
959
960 %files mod_memcache
961 %doc doc/modules/mod_memcache.html
962 %config(noreplace) %{_sysconfdir}/%{name}.d/40_mod_memcache.conf
963 %{_libdir}/%{name}/mod_memcache.so

  ViewVC Help
Powered by ViewVC 1.1.30