1 |
< |
### RPM cms prodagent 0.1 |
2 |
< |
## INITENV +PATH PYTHONPATH %i/lib/python |
3 |
< |
%define cvstag pe20060403 |
4 |
< |
Source: cvs://:pserver:anonymous@cmscvs.cern.ch:2401/cvs_server/repositories/CMSSW?passwd=AA_:yZZ3e&module=MCPROTO&export=MCPROTO&&tag=-r%{cvstag}&output=/MCPROTO.tar.gz |
5 |
< |
Requires: python mysql py2-mysqldb dbs dls |
1 |
> |
### RPM cms prodagent PRODAGENT_0_1_1 |
2 |
> |
## INITENV +PATH PYTHONPATH %i/lib |
3 |
> |
|
4 |
> |
%define cvstag %v |
5 |
> |
Source: cvs://:pserver:anonymous@cmscvs.cern.ch:2401/cvs_server/repositories/CMSSW?passwd=AA_:yZZ3e&module=PRODAGENT&export=PRODAGENT&&tag=-r%{cvstag}&output=/PRODAGENT.tar.gz |
6 |
> |
Requires: python mysql py2-mysqldb dbs dls boss prodcommon openssl |
7 |
|
|
8 |
|
%prep |
9 |
< |
%setup -n MCPROTO |
9 |
> |
%setup -n PRODAGENT |
10 |
|
%build |
10 |
– |
mkdir -p %i/lib/python |
11 |
– |
PYTHONPATH=%_builddir/MCPROTO/src/python:$PYTHONPATH |
12 |
– |
PRODAGENT_DIR=%i/lib/python ; export PRODAGENT_DIR |
13 |
– |
DBS_CLIENT_DIR=$DBS_ROOT; export DBS_CLIENT_DIR |
14 |
– |
DLS_CLIENT_DIR=$DLS_ROOT; export DLS_CLIENT_DIR |
15 |
– |
|
16 |
– |
python install/configure.py |
11 |
|
%install |
12 |
< |
mkdir -p %i/lib/python |
13 |
< |
mkdir -p %i/share |
14 |
< |
cp -r ./src/python %i/lib |
15 |
< |
cp -r ./src/sql %i/share |
12 |
> |
make PREFIX=%i install |
13 |
> |
mkdir -p %i/bin |
14 |
> |
cp bin/prod* %{i}/bin |
15 |
> |
mkdir -p %i/test |
16 |
> |
cp -R test/* %i/test/ |
17 |
> |
mkdir -p %i/util |
18 |
> |
cp -R util/* %i/util/ |
19 |
> |
mkdir -p %{i}/etc/profile.d |
20 |
> |
mkdir -p %i/workdir |
21 |
> |
|
22 |
> |
(echo "#!/bin/sh"; \ |
23 |
> |
echo "source $PYTHON_ROOT/etc/profile.d/init.sh"; \ |
24 |
> |
echo "source $MYSQL_ROOT/etc/profile.d/init.sh"; \ |
25 |
> |
echo "source $PY2_MYSQLDB_ROOT/etc/profile.d/init.sh"; \ |
26 |
> |
echo "source $DBS_ROOT/etc/profile.d/init.sh"; \ |
27 |
> |
echo "source $DLS_ROOT/etc/profile.d/init.sh"; \ |
28 |
> |
echo "source $PRODCOMMON_ROOT/etc/profile.d/init.sh"; \ |
29 |
> |
echo "source $BOSS_ROOT/etc/profile.d/init.sh" ) > %{i}/etc/profile.d/dependencies-setup.sh |
30 |
> |
|
31 |
> |
(echo "#!/bin/tcsh"; \ |
32 |
> |
echo "source $PYTHON_ROOT/etc/profile.d/init.csh"; \ |
33 |
> |
echo "source $MYSQL_ROOT/etc/profile.d/init.csh"; \ |
34 |
> |
echo "source $PY2_MYSQLDB_ROOT/etc/profile.d/init.csh"; \ |
35 |
> |
echo "source $DBS_ROOT/etc/profile.d/init.csh"; \ |
36 |
> |
echo "source $DLS_ROOT/etc/profile.d/init.csh"; \ |
37 |
> |
echo "source $PRODCOMMON_ROOT/etc/profile.d/init.csh"; \ |
38 |
> |
echo "source $BOSS_ROOT/etc/profile.d/init.csh" ) > %{i}/etc/profile.d/dependencies-setup.csh |
39 |
> |
|
40 |
> |
%post |
41 |
> |
%{relocateConfig}etc/profile.d/dependencies-setup.sh |
42 |
> |
%{relocateConfig}etc/profile.d/dependencies-setup.csh |