use Makefile to build and install
[plcapi.git] / PLCAPI.spec
1 Summary: PlanetLab Central API
2 Name: PLCAPI
3 Version: 4.0
4 Release: 1
5 License: PlanetLab
6 Group: System Environment/Daemons
7 URL: http://cvs.planet-lab.org/cvs/new_plc_api
8 Source0: %{name}-%{version}.tar.gz
9 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
10
11 Obsoletes: plcapilib
12
13 # OpenJade does not honor XML catalog files and tries to access
14 # www.oasis-open.org even if DTDs are locally installed. Disable
15 # documentation generation for now.
16 # BuildRequires: docbook-dtds, docbook-utils-pdf
17
18 Requires: postgresql-server, SOAPpy
19
20 %description
21 The PLCAPI package provides an XML-RPC and SOAP API for accessing the
22 PlanetLab Central (PLC) database. The API may be accessed directly via
23 the Python shell program plcsh, through a toy standalone server, or
24 through Apache mod_python.
25
26 %prep
27 %setup -q
28
29 %build
30 # Build __init__.py metafiles and PHP API. Do not build documentation
31 # for now.
32 %{__make} %{?_smp_mflags} SUBDIRS=php
33
34 %install
35 rm -rf $RPM_BUILD_ROOT
36 %{__make} %{?_smp_mflags} install DESTDIR="$RPM_BUILD_ROOT" datadir="%{_datadir}" bindir="%{_bindir}"
37
38 # Install shell symlink
39 mkdir -p $RPM_BUILD_ROOT/%{_bindir}
40 ln -s %{_datadir}/plc_api/Shell.py $RPM_BUILD_ROOT/%{_bindir}/plcsh
41
42 %clean
43 rm -rf $RPM_BUILD_ROOT
44
45 %files
46 %defattr(-,root,root,-)
47 %doc doc/PLCAPI.xml doc/PLCAPI.pdf doc/PLCAPI.html
48 %dir %{_datadir}/plc_api
49 %{_datadir}/plc_api/*
50 %{_bindir}/plcsh
51
52 %changelog
53 * Fri Oct 27 2006 Mark Huang <mlhuang@CS.Princeton.EDU> - 
54 - Initial build.
55