ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/CMSDIST/systemtools.spec
(Generate patch)

Comparing COMP/CMSDIST/systemtools.spec (file contents):
Revision 1.1 by muzaffar, Mon Sep 3 15:28:46 2007 UTC vs.
Revision 1.26 by davidlt, Thu Mar 1 13:39:08 2012 UTC

# Line 1 | Line 1
1 < ### RPM virtual systemtools 1.0
1 > ### RPM external systemtools 19
2 > ## NOCOMPILER
3   Source: none
4 + Requires: oracle-env
5  
6 < %define systemtools                     sockets opengl x11 jcompiler
7 < %define sockets_version                 1.0
8 < %define opengl_version                  XFree4.2
9 < %define x11_version                     R6
10 < %define jcompiler_version               1.5.0.p6
11 <
12 < ## INITENV SET SOCKETS_VERSION          %sockets_version
13 < ## INITENV SET OPENGL_VERSION           %opengl_version
14 < ## INITENV SET X11_VERSION              %x11_version
15 < ## INITENV SET JCOMPILER_VERSION        %jcompiler_version
16 < ## INITENV SET JCOMPILER_TOOL           java-jdk
17 < ## INITENV SET PKGTOOLS_SYSTEM_TOOLS    %systemtools
6 > %if "%{?use_system_gcc:set}" == "set"
7 > %define compilertools ccompiler cxxcompiler f77compiler
8 > %else
9 > %define compilertools %{nil}
10 > %endif
11 >
12 > %define systemtools                     sockets opengl x11 %compilertools
13 > %define sockets_version                 1.0
14 > %define opengl_version                  XFree4.2
15 > %define x11_version                     R6
16 >
17 > ## INITENV SETV SOCKETS_VERSION         %sockets_version
18 > ## INITENV SETV OPENGL_VERSION          %opengl_version
19 > ## INITENV SETV X11_VERSION             %x11_version
20 > ## INITENV SETV PKGTOOLS_SYSTEM_TOOLS   %systemtools
21  
22   %prep
23   %build
# Line 20 | Line 25 | Source: none
25   # SCRAM ToolBox toolfile
26   mkdir -p %i/etc/scram.d
27   # Sockets
28 < cat << \EOF_TOOLFILE >%i/etc/scram.d/sockets
29 < <doc type=BuildSystem::ToolDoc version=1.1>
25 < <Tool name=Sockets version=%sockets_version>
28 > cat << \EOF_TOOLFILE >%i/etc/scram.d/sockets.xml
29 >  <tool name="sockets" version="%sockets_version">
30   EOF_TOOLFILE
31   case %cmsplatf in
32 < slc3_* | slc4_* )
33 < cat << \EOF_TOOLFILE >>%i/etc/scram.d/sockets
34 < <lib name=nsl>
35 < <lib name=crypt>
36 < <lib name=dl>
32 > slc4_* | slc4onl_* | slc5_* | slc5onl_* | slc6_* )
33 > cat << \EOF_TOOLFILE >>%i/etc/scram.d/sockets.xml
34 >    <lib name="nsl"/>
35 >    <lib name="crypt"/>
36 >    <lib name="dl"/>
37 >    <lib name="rt"/>
38   EOF_TOOLFILE
39   ;;
40   osx10* )
41 < cat << \EOF_TOOLFILE >>%i/etc/scram.d/sockets
42 < <lib name=dl>
41 > cat << \EOF_TOOLFILE >>%i/etc/scram.d/sockets.xml
42 >    <lib name="dl"/>
43   EOF_TOOLFILE
44   ;;
45   esac
46 < echo "</Tool>" >>%i/etc/scram.d/sockets
46 > echo "  </tool>" >>%i/etc/scram.d/sockets.xml
47  
48   # OpenGL
49 < cat << \EOF_TOOLFILE >%i/etc/scram.d/opengl
50 < <doc type=BuildSystem::ToolDoc version=1.1>
51 < <Tool name=OpenGL version=%opengl_version>
52 < <use name=X11>
53 < <lib name=GL>
54 < <lib name=GLU>
49 > cat << \EOF_TOOLFILE >%i/etc/scram.d/opengl.xml
50 >  <tool name="opengl" version="%opengl_version">
51 >    <lib name="GL"/>
52 >    <lib name="GLU"/>
53 >    <use name="x11"/>
54 >    <environment name="ORACLE_ADMINDIR" default="@ORACLE_ENV_ROOT@/etc"/>
55   EOF_TOOLFILE
56   case %cmsplatf in
57 < osx103* )
58 < cat << \EOF_TOOLFILE >>%i/etc/scram.d/opengl
59 < <Client>
60 < <Environment name=OPENGL_BASE default="/System/Library/Frameworks/OpenGL.framework/Versions/A"></Environment>
61 < <Environment name=INCLUDE default="$OPENGL_BASE/Headers"></Environment>
62 < <Environment name=LIBDIR default="$OPENGL_BASE/Libraries"></Environment>
63 < </Client>
57 > osx* )
58 > cat << \EOF_TOOLFILE >>%i/etc/scram.d/opengl.xml
59 >    <client>
60 >      <environment name="OPENGL_BASE" default="/System/Library/Frameworks/OpenGL.framework/Versions/A"/>
61 >      <environment name="INCLUDE"     default="$OPENGL_BASE/Headers"/>
62 >      <environment name="LIBDIR"      default="$OPENGL_BASE/Libraries"/>
63 >    </client>
64   EOF_TOOLFILE
65   ;;
66   esac
67 < echo "</Tool>" >>%i/etc/scram.d/opengl
67 > echo "  </tool>" >>%i/etc/scram.d/opengl.xml
68  
69   # X11
70 < cat << \EOF_TOOLFILE >%i/etc/scram.d/x11
71 < <doc type=BuildSystem::ToolDoc version=1.1>
67 < <Tool name=X11 version=%x11_version>
70 > cat << \EOF_TOOLFILE >%i/etc/scram.d/x11.xml
71 >  <tool name="x11" version="%x11_version">
72   EOF_TOOLFILE
73   case %cmsplatf in
74 < slc3_* )
75 < cat << \EOF_TOOLFILE >>%i/etc/scram.d/x11
76 < <Client>
77 < <Environment name=INCLUDE value="/usr/X11R6/include"></Environment>
78 < <Environment name=LIBDIR value="/usr/X11R6/lib"></Environment>
79 < </Client>
80 < <lib name=Xt>
81 < <lib name=Xpm>
82 < <lib name=X11>
83 < <lib name=Xi>
84 < <lib name=Xext>
85 < <lib name=Xmu>
86 < <lib name=ICE>
87 < <lib name=SM>
74 > osx* )
75 > cat << \EOF_TOOLFILE >>%i/etc/scram.d/x11.xml
76 >    <client>
77 >      <environment name="INCLUDE" value="/usr/X11R6/include"/>
78 >      <environment name="LIBDIR" value="/usr/X11R6/lib"/>
79 >    </client>
80 >    <runtime name="DYLD_FALLBACK_LIBRARY_PATH" value="$LIBDIR" type="path"/>
81 >    <lib name="Xt"/>
82 >    <lib name="Xpm"/>
83 >    <lib name="X11"/>
84 >    <lib name="Xi"/>
85 >    <lib name="Xext"/>
86 >    <lib name="Xmu"/>
87 >    <lib name="ICE"/>
88 >    <lib name="SM"/>
89   EOF_TOOLFILE
90   ;;
91   esac
92 < cat << \EOF_TOOLFILE >>%i/etc/scram.d/x11
93 < <use name=sockets>
94 < </Tool>
90 < EOF_TOOLFILE
91 <
92 < # JCompiler
93 < %define compiler_ver        %(echo %jcompiler_version | sed -e "s|\\.||g")
94 < cat << \EOF_TOOLFILE >>%i/etc/scram.d/jcompiler
95 < <doc type=BuildSystem::ToolDoc version=1.1>
96 < <Tool name=jcompiler version=%jcompiler_version type=compiler>
97 < <Client>
98 < <Environment name=JAVA_BASE></Environment>
99 < <Environment name=JAVAC value="$JAVA_BASE/bin/javac"></Environment>
100 < </Client>
101 < <Runtime name=JAVA_HOME default="$JAVA_BASE">
102 < <flags JAVAC_="$(JAVAC)">
103 < <flags JAVAC_o="$(JAVAC) -O">
104 < <flags JAVAC_d="$(JAVAC) -g">
105 < <Flags SCRAM_COMPILER_NAME="jsdk%compiler_ver">
106 < <Flags SCRAM_LANGUAGE_TYPE="JAVA">
107 < </Tool>
92 > cat << \EOF_TOOLFILE >>%i/etc/scram.d/x11.xml
93 >    <use name="sockets"/>
94 >  </tool>
95   EOF_TOOLFILE
96  
97 + export ORACLE_ENV_ROOT
98 + perl -p -i -e 's|\@([^@]*)\@|$ENV{$1}|g' %i/etc/scram.d/*.xml
99 +
100   %post
101 < %{relocateConfig}etc/scram.d/sockets
112 < %{relocateConfig}etc/scram.d/opengl
113 < %{relocateConfig}etc/scram.d/x11
114 < %{relocateConfig}etc/scram.d/jcompiler
101 > %{relocateConfig}etc/scram.d/*.xml

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines