4 |
|
%define perlversion %(perl -e 'printf "%%vd", $^V') |
5 |
|
%define perlarch %(perl -MConfig -e 'print $Config{archname}') |
6 |
|
%define downloadn DBD-Oracle |
7 |
+ |
%define online %(case %cmsplatf in *onl_*_*) echo true ;; esac) |
8 |
|
|
9 |
< |
%if "%cmsplatf" != "slc4onl_ia32_gcc346" |
9 |
> |
%if "%online" != "true" |
10 |
|
Requires: p5-dbi oracle |
11 |
|
%define oraclesdksrc none |
12 |
|
%else |
13 |
|
# we still need oracle sdk makefiles: |
14 |
< |
%define oraclesdksrc http://cmsrep.cern.ch/cms/cpt/Software/download/cms/SOURCES/external/oracle/10.2.0.3-CMS18/instantclient-sdk-linux32-10.2.0.3-20061115.zip |
14 |
> |
%define oraclesdksrc http://cmsrep.cern.ch/cmssw/oracle-mirror/slc4_ia32/10.2.0.3/sdk.zip |
15 |
|
%endif |
16 |
|
|
17 |
|
Source0: http://mirror.switch.ch/ftp/mirror/CPAN/authors/id/P/PY/PYTHIAN/%downloadn-%{realversion}.tar.gz |
22 |
|
%prep |
23 |
|
%setup -T -b 0 -n %{downloadn}-%{realversion} |
24 |
|
|
25 |
< |
%if "%cmsplatf" == "slc4onl_ia32_gcc346" |
25 |
> |
%if "%online" == "true" |
26 |
|
rm -rf instantclient_* |
27 |
< |
yes | unzip %_sourcedir/*-sdk-*linux32*.zip |
27 |
> |
yes | unzip %_sourcedir/sdk.zip |
28 |
|
%endif |
29 |
|
|
30 |
|
%build |
37 |
|
perl -p -i -e 's/NMEDIT = nmedit/NMEDIT = true/' Makefile.PL |
38 |
|
%endif |
39 |
|
|
40 |
< |
%if "%cmsplatf" != "slc4onl_ia32_gcc346" |
40 |
> |
%if "%online" != "true" |
41 |
|
perl Makefile.PL PREFIX=%i LIB=%i/lib/site_perl/%perlversion -l -m $ORACLE_HOME/demo/demo.mk |
42 |
|
%else |
43 |
|
export ORACLE_HOME="/opt/xdaq" |