source: trunk/server/fedora/specs/moira.spec @ 1394

Last change on this file since 1394 was 1394, checked in by gdb, 14 years ago
Added mostly-working spec file for moira
File size: 5.0 KB
Line 
1Summary: rpm packaging of libmoira
2Group: Applications/System
3Name: moira
4Version: 0.%{scriptsversion}
5Release: 0
6Vendor: The scripts.mit.edu Team (scripts@mit.edu)
7URL: http://scripts.mit.edu
8License: GPL
9Source: %{name}.tar.gz
10Source1: debian/debathena-moira-update-server.init
11BuildRoot: %{_tmppath}/%(%{__id_u} -n)-%{name}-%{version}-root
12#TODO: might really need mit-zephyr-devel, something for autotools-dev
13BuildRequires: readline-devel, patch, e2fsprogs-devel, mit-zephyr, ncurses-devel, krb5-devel, hesiod-devel
14patch0: debian/patches/install-headers
15
16%description
17rpm packaging of libmoira
18
19Source package for the moira library and clients.  Clone of debathena-moira.
20See http://scripts.mit.edu/wiki for more information.
21
22%prep
23%setup -q -n %{name}
24cp -p /home/scripts-build/test/trunk/server/fedora/specs/mybuild/moira-update-server.init %{SOURCE1}
25%patch0 -p1
26
27%build
28# Hack: Add /usr/include/et to put com_err.h on the C include path.
29# Can remove this once the maintainer of the relevant package symlinks
30# com_err.h in /usr/include.
31# TODO: --with-zephyr is currently borked
32%configure --without-krb4 --with-krb5 --with-hesiod --without-zephyr --without-oracle --without-afs --disable-rpath --with-com_err=/usr CFLAGS='-I /usr/include/et'
33make %{?_smp_mflags}
34
35%install
36rm -rf %{buildroot}
37make install DESTDIR=%{buildroot}
38mv %{buildroot}/%{_bindir}/chfn %{buildroot}/%{_bindir}/chfn.moira
39mv %{buildroot}/%{_bindir}/chsh %{buildroot}/%{_bindir}/chsh.moira
40mv %{buildroot}/%{_mandir}/man1/chsh.1 \
41   %{buildroot}/%{_mandir}/man1/chsh.moira.1
42mv %{buildroot}/%{_mandir}/man1/chfn.1 \
43   %{buildroot}/%{_mandir}/man1/chfn.moira.1
44install -m 755 -d %{buildroot}/%{_initddir}
45install -m 755 %{SOURCE1} %{buildroot}/%{_initddir}/moira-update-server
46# Hack: These man files are installed but no package uses them
47rm %{buildroot}/%{_mandir}/man8/dcm.8
48rm %{buildroot}/%{_mandir}/man8/moirad.8
49rm %{buildroot}/%{_mandir}/man8/reg_svr.8
50rm %{buildroot}/%{_mandir}/man8/setquota.8
51rm %{buildroot}/%{_mandir}/man8/startdcm.8
52rm %{buildroot}/%{_mandir}/man8/startmoira.8
53rm %{buildroot}/%{_mandir}/man8/startreg.8
54
55%clean
56rm -rf %{buildroot}
57
58%changelog
59* Fri Dec 26 2009  Greg Brockman <gdb@mit.edu>
60- prerelease
61
62# moira-clients
63%package moira-clients
64Summary: Clients for the Moira database
65Group: Applications/System
66%description moira-clients
67Clients for the Moira database
68
69Moira is the Athena Service Management system.  It serves as the
70central repository for information about users, groups hosts, print
71queues, and several other aspects of the Athena environment.
72
73This package contains clients such as moira, stella, blanche, etc.
74
75%files moira-clients
76%{_bindir}/addusr
77%{_bindir}/blanche
78%{_bindir}/chfn.moira
79%{_bindir}/chpobox
80%{_bindir}/chsh.moira
81%{_bindir}/mitch
82%{_bindir}/namespace
83%{_bindir}/moira
84%{_bindir}/mrcheck
85%{_bindir}/mrtest
86%{_bindir}/stanley
87%{_bindir}/stella
88%{_bindir}/mailmaint
89%{_bindir}/listmaint
90%{_bindir}/dcmmaint
91%{_bindir}/usermaint
92%{_bindir}/update_test
93%doc %{_mandir}/man1/*
94%doc %{_mandir}/man8/mrtest.8.gz
95
96
97# moira-update-server
98%package moira-update-server
99Summary: Athena update_server
100Group: Applications/System
101Requires(post): chkconfig
102Requires(preun): chkconfig
103%description moira-update-server
104Athena update_server
105
106Moira is the Athena Service Management system.  It serves as the
107central repository for information about users, groups hosts, print
108queues, and several other aspects of the Athena environment.
109
110This package contains the update_server daemon, which is used for
111servers that automatically receive information dumps from moira.
112
113%files moira-update-server
114%defattr(-,root,root)
115%doc %{_mandir}/man8/update_server.8.gz
116%config(noreplace) %{_sysconfdir}/athena/moira.conf
117%defattr(755,root,root)
118%{_sbindir}/update_server
119%{_initddir}/moira-update-server
120
121%post moira-update-server
122/sbin/chkconfig --add moira-update-server
123
124%preun moira-update-server
125if [ $1 = 0 ] ; then
126    /sbin/service moira-update-server stop >/dev/null 2>&1
127    /sbin/chkconfig --del moira-update-server
128fi
129
130# libmoira0
131%package libmoira0
132Summary: The Moira library
133Group: System Environment/Libraries
134%description libmoira0
135The Moira library
136
137Moira is the Athena Service Management system.  It serves as the
138central repository for information about users, groups hosts, print
139queues, and several other aspects of the Athena environment.
140
141This package contains the shared Moira library.
142
143%files libmoira0
144%{_libdir}/libmoira.so.*
145
146# libmoira-dev
147%package libmoira-dev
148Summary: Development files for Moira library
149Group: Development/Libraries
150Provides: libmoira-dev
151Requires: libmoira0
152%description libmoira-dev
153Development files for Moira library
154
155Moira is the Athena Service Management system.  It serves as the
156central repository for information about users, groups hosts, print
157queues, and several other aspects of the Athena environment.
158
159This package contains headers and static libraries for development.
160
161%files libmoira-dev
162%defattr(-,root,root)
163%{_includedir}/*
164%doc %{_mandir}/man3/*
165%{_libdir}/libmoira.so
166%{_libdir}/libmoira.la
167%{_libdir}/libmoira.a
Note: See TracBrowser for help on using the repository browser.