Revision: | 1.14 |
Committed: | Wed Aug 2 12:47:02 2006 UTC (18 years, 8 months ago) by eulisse |
Branch: | MAIN |
Changes since 1.13: | +2 -2 lines |
Log Message: | Fixes the problems introduced by the simplify script. |
# | User | Rev | Content |
---|---|---|---|
1 | eulisse | 1.8 | ### RPM external xdaq 3.5 |
2 | ratnik | 1.13 | Requires: zlib |
3 | Requires: oracle | ||
4 | eulisse | 1.7 | %define xdaqv %(echo %v |tr . _) |
5 | eulisse | 1.2 | %define libext so |
6 | eulisse | 1.7 | # Download from cern afs area to speed up testing: |
7 | #Source0: http://cmsdoc.cern.ch/Releases/XDAQ/XDAQ_%xdaqv/coretools_G_17559_V%xdaqv.tgz | ||
8 | #Source1: http://cmsdoc.cern.ch/Releases/XDAQ/XDAQ_%xdaqv/powerpack_G_28175_V1_3_1.tgz | ||
9 | #Source2: http://cmsdoc.cern.ch/Releases/XDAQ/XDAQ_%xdaqv/worksuite_G_28176_V1_4.tgz | ||
10 | Source0: http://switch.dl.sourceforge.net/sourceforge/xdaq/coretools_G_17559_V%{xdaqv}.tgz | ||
11 | Source1: http://switch.dl.sourceforge.net/sourceforge/xdaq/powerpack_G_28175_V1_4.tgz | ||
12 | Source2: http://switch.dl.sourceforge.net/sourceforge/xdaq/worksuite_G_28176_V1_5.tgz | ||
13 | ratnik | 1.5 | |
14 | eulisse | 1.7 | %prep |
15 | %setup -T -b 0 -n TriDAS | ||
16 | %setup -D -T -b 1 -n TriDAS | ||
17 | %setup -D -T -b 2 -n TriDAS | ||
18 | eulisse | 1.11 | ls |
19 | perl -p -i -e "s|^#.*ksh(.*)|#!/usr/bin/env ksh $1|" daq/extern/SBSVME/1003/v2p3p0/sys/makefile \ | ||
20 | daq/extern/SBSVME/1003/v2p3p0/sys/mkbtp | ||
21 | eulisse | 1.7 | echo " Install root in prep:" %{i} %{pkginstroot} |
22 | ratnik | 1.1 | |
23 | %build | ||
24 | # Xdaq does not provide makeinstall, it uses "simplify" script instead to | ||
25 | # reorganize the directory structure after the build is done. | ||
26 | # Therefore build is done in the install area. | ||
27 | |||
28 | %install | ||
29 | # Copy all code into the installation area, and build directly there: | ||
30 | cp -rp * %{i} # assuming there are no symlinks in the original source code | ||
31 | cd %{i} | ||
32 | export XDAQ_ROOT=$PWD | ||
33 | cd %{i}/daq | ||
34 | eulisse | 1.2 | make Set=extern |
35 | ratnik | 1.1 | make Set=coretools |
36 | eulisse | 1.7 | make Set=powerpack |
37 | make Set=worksuite | ||
38 | ratnik | 1.13 | cd tstore |
39 | make ORACLE_INCLUDE=$ORACLE_ROOT/include ORACLE_LIB=$ORACLE_ROOT/lib | ||
40 | ratnik | 1.1 | # The following structure used as defined in Xdaq "simplify" script: |
41 | cd %{i} | ||
42 | eulisse | 1.2 | mkdir -p %{i}/lib |
43 | mkdir -p %{i}/bin | ||
44 | ratnik | 1.1 | # Catch-all |
45 | eulisse | 1.14 | find . -type f ! -path "./lib/*.%{libext}" -name "*.%{libext}" -exec ln -sf {} %{i}/lib \; |
46 | find . -type f ! -path "./bin/*.exe" -name "*.exe" -exec ln -sf {} %{i}/bin; ln -sf \; | ||
47 | ratnik | 1.1 | |
48 | # Libraries from extern (not found cause they are symlinks) | ||
49 | eulisse | 1.3 | cp -rdL daq/extern/*/linuxx86/lib/* %{i}/lib |
50 | |||
51 | find daq -type f ! -path "*/extern/*lib*" -name "*.a" -exec cp {} %{i}/lib \; | ||
52 | eulisse | 1.11 | perl -p -i -e "s|^#!.*make|#!/usr/bin/env make|" %{i}/daq/extern/slp/openslp-1.2.0/debian/rules |
53 | eulisse | 1.12 | %post |
54 | find $RPM_INSTALL_PREFIX/%pkgrel -type l | xargs ls -la | sed -e "s|.*[ ]\(/.*\) -> \(.*\)| \2 \1|;s|[ ]/[^ ]*/external| $RPM_INSTALL_PREFIX/%cmsplatf/external|g" | ||
55 | find $RPM_INSTALL_PREFIX/%pkgrel -type l | xargs ls -la | sed -e "s|.*[ ]\(/.*\) -> \(.*\)| \2 \1|;s|[ ]/[^ ]*/external| $RPM_INSTALL_PREFIX/%cmsplatf/external|g" | xargs -n2 ln -sf |