-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathymdial.spec.tmp
66 lines (45 loc) · 954 Bytes
/
ymdial.spec.tmp
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
Name: ymdial
Version: @VERSION@
Release: @RELEASE@%{dist}
Summary: YAMU ymdial
Group: Applications/Internet
License: GPL
URL: http://www.yamutech.com
Source0: ymdial-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}
%description
YAMU ymdial
%prep
%setup -q -n ymdial-%{version}
%build
#make %{?_smp_mflags}
make
%install
rm -rf %{buildroot}
mkdir -p %{buildroot}/%{_bindir}
mkdir -p %{buildroot}/etc/
mkdir -p %{buildroot}/etc/init.d
mkdir -p %{buildroot}/var/log/ymdial
install -m 755 ymdial %{buildroot}/%{_bindir}/ymdial
install -m 755 config/ymdial.ini %{buildroot}/etc/
install -m 755 config/ymdiald %{buildroot}/etc/init.d/
%clean
rm -rf %{buildroot}
%post
if [ "$1" = "1" ]
then
chkconfig --add ymdiald
fi
%files
%defattr(-,root,root,-)
%{_bindir}/ymdial
/etc/ymdial.ini
%config/etc/ymdial.ini
/var/log/ymdial/
/etc/init.d/ymdiald
%preun
if [ "$1" = "0" ]
then
chkconfig --del ymdiald
fi
%changelog