-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathspec
68 lines (59 loc) · 1.63 KB
/
spec
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
Name: @PACKAGE@
Summary: Secure, simple, and efficient FTP server
Version: @VERSION@
Release: 1
License: GPL
Group: Utilities/System
Source: http://untroubled.org/@PACKAGE@/@PACKAGE@-@VERSION@.tar.gz
BuildRoot: %{_tmppath}/@PACKAGE@-buildroot
URL: http://untroubled.org/@PACKAGE@/
Packager: Bruce Guenter <bruce@untroubled.org>
BuildRequires: bglibs >= 2.02
BuildRequires: cvm-devel >= 0.90
Requires: supervise-scripts >= 3.5
Requires: cvm
%description
This is twoftpd, a new FTP server that strives to be secure, simple, and
efficient.
%prep
%setup
%build
echo "gcc ${optflags} -D_FILE_OFFSET_BITS=64" >conf-cc
echo "gcc -s" >conf-ld
echo %{_bindir} >conf-bin
echo %{_mandir} >conf-man
make programs
%install
rm -fr %{buildroot}
mkdir -p %{buildroot}%{_bindir}
mkdir -p %{buildroot}%{_mandir}
make install install_prefix=%{buildroot}
mkdir -p %{buildroot}/etc/twoftpd
pushd %{buildroot}/etc/twoftpd
echo 1 >CHROOT
echo 900 >TIMEOUT
echo 1 >LOGREQUESTS
echo 1 >LOGRESPONSES
popd
mkdir -p %{buildroot}/var/log/twoftpd
mkdir -p %{buildroot}/var/service/twoftpd/log
install -m 755 twoftpd.run %{buildroot}/var/service/twoftpd/run
install -m 755 twoftpd-log.run %{buildroot}/var/service/twoftpd/log/run
%clean
rm -rf %{buildroot}
%post
if ! [ -e /service/twoftpd ]; then
svc-add -d /var/service/twoftpd
fi
%files
%defattr(-,root,root)
%doc COPYING NEWS README
%dir /etc/twoftpd
%config(noreplace) /etc/twoftpd/*
%{_bindir}/*
%{_mandir}/*
%attr(0700,root,root) %dir /var/log/twoftpd
%attr(1755,root,root) %dir /var/service/twoftpd
%dir /var/service/twoftpd/log
%config(noreplace) /var/service/twoftpd/log/run
%config(noreplace) /var/service/twoftpd/run