Skip to content

Commit 5449a90

Browse files
committed
ode4linux: adding ode.spec from SRPM
At some point build.sh will including the install builds, once it's converted to a Makefile. Signed-off-by: Andrei Warkentin <andrey.warkentin@gmail.com>
1 parent 1740a79 commit 5449a90

1 file changed

Lines changed: 313 additions & 0 deletions

File tree

ode.spec.historical

Lines changed: 313 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,313 @@
1+
Summary: The OSF Development Environment
2+
Name: ode
3+
Version: 2.3.4
4+
Release: 5f
5+
Group: Development/Tools
6+
Vendor: MkLinux.org
7+
# I don't know if this is officially distributed anywhere.
8+
Source: ode4linux.tar.gz
9+
Patch0: ode-geoffk.patch
10+
Patch1: ode-sbinfo.patch
11+
Patch2: ode-fwb.patch
12+
Patch3: ode-ppcbootstrap.patch
13+
Patch4: ode-setup.patch
14+
Copyright: Redistributable
15+
BuildRoot: /tmp/ode-root
16+
Prefix: /opt/ode
17+
ExclusiveArch: ppc i386
18+
19+
%description
20+
This is part of the build environment the Open Software Foundation
21+
uses to build their kernels. It is used by Apple to build the MkLinux
22+
Mach kernel.
23+
24+
%package scontrol
25+
Summary: The OSF Development Environment source control tools
26+
Prefix: /opt/ode
27+
Requires: ode rcs
28+
Group: Development/Tools
29+
30+
%description scontrol
31+
This is the source control part of the Open Software Foundation's
32+
development environment. You probably only need this if you are working
33+
with OSF.
34+
35+
%package psdocs
36+
Summary: The OSF Development Environment Documentation
37+
Prefix: /opt/ode
38+
Group: Documentation
39+
40+
%description psdocs
41+
The ODE psdocs package contains postscript versions of the
42+
OSF Development Environment System Administrator's Guide, the
43+
ODE User's Guide and printable postscript versions of the man
44+
pages. You will only need this if you are interested in using
45+
or customizing ODE for your your own projects or if you simply
46+
want to learn how ODE works.
47+
48+
%changelog
49+
50+
* Mon May 03 1999 Fred Bacon <bacon@aerodyne.com>
51+
- Since the System Administration Guide recommends building
52+
your sandbox with pieces from the ode sandbox, I've added
53+
the various configuration files.
54+
55+
* Sun May 02 1999 Fred Bacon <bacon@aerodyne.com>
56+
- I believe that I finally have things setup so that ODE can be
57+
bootstrapped onto a system which doesn't have a pre-existing
58+
copy of ODE.
59+
60+
* Sat May 01 1999 Fred Bacon <bacon@aerodyne.com>
61+
- Added a new package to distribute the ODE System Administrators'
62+
Guide, the ODE User's Guide and the man pages in postscript format.
63+
- Added the README files to the list of documentation
64+
65+
* Sun Jan 24 1999 Fred Bacon <bacon@aerodyne.com>
66+
- Moved installation from /usr/bin/lib to /opt/ode
67+
- Fixed a number of build problems (mult. definitions of strndup, etc.)
68+
69+
* Sat Jan 09 1999 Geoff Keating <geoffk@ozemail.com.au>
70+
- New package.
71+
72+
%prep
73+
%setup -q -n ode4linux
74+
%patch0 -p1 -b .patch0
75+
%patch1 -p1 -b .patch1
76+
%patch2 -p1 -b .patch2
77+
# This patch is needed to bootstrap on a powerpc linux box
78+
%ifarch ppc
79+
%patch3 -p1 -b .patch3
80+
%endif
81+
# I've added workon to the list of tools which are
82+
# built during the bootstrap stage.
83+
%patch4 -p1 -b .patch4
84+
85+
cat > sandboxrc <<EOF
86+
default ode4linux
87+
base * $RPM_BUILD_DIR
88+
sb ode4linux
89+
EOF
90+
cat > rc_files/ode/sb.conf <<EOF
91+
replace ode_sc true
92+
replace ode_build_env true
93+
EOF
94+
95+
%build
96+
#
97+
# Set the proper context and bootstrap the environment.
98+
#
99+
%ifarch ppc
100+
context=ppc_linux
101+
%else
102+
context=at386_linux
103+
%endif
104+
cd src
105+
export context=${context}
106+
export OS=linux
107+
echo $context
108+
sh +x ode/setup/setup.sh ${context}
109+
110+
#
111+
# Now we can actually begin to build ODE
112+
# There seems to be something missing in the bootstrap
113+
# sequence. It is necessary to link directly to the
114+
# LINUXARCH/arch_fmtdeps.c file. We aren't finding it
115+
# on our own the way we would if the full ODE build
116+
# environment were available.
117+
#
118+
cd ..
119+
mkdir logs/${context}
120+
ln -s ${RPM_BUILD_DIR}/ode4linux/src/ode/bin/make/LINUXARCH/arch_fmtdep.c src/ode/bin/make/arch_fmtdep.c
121+
export PATH="${RPM_BUILD_DIR}/ode4linux/tools/${context}/bin:$PATH"
122+
export context=${context}
123+
export OS=linux
124+
workon -sb ode4linux -rc `pwd`/sandboxrc <<EOF
125+
set -x
126+
build -here MAKEFILE_PASS=FIRST && \
127+
build -here MAKEFILE_PASS=SECOND CC_OPT_LEVEL=-O2 && \
128+
build MAKEFILE_PASS=BASIC ode/lib/oxm_relay_tcp CC_OPT_LEVEL=-O2 && \
129+
build -here MAKEFILE_PASS=BASIC CC_OPT_LEVEL=-O2 ode/bin ode/server && \
130+
build -here MAKEFILE_PASS=BASIC ode/man ode/doc
131+
EOF
132+
133+
%install
134+
%ifarch ppc
135+
context=ppc_linux
136+
%else
137+
context=at386_linux
138+
%endif
139+
140+
rm -rf $RPM_BUILD_ROOT
141+
mkdir $RPM_BUILD_ROOT
142+
mkdir -p $RPM_BUILD_ROOT/opt/ode/{bin,server,man,lib}
143+
mkdir -p $RPM_BUILD_ROOT/usr/bin
144+
145+
for i in 1 5 8 ; do
146+
mkdir $RPM_BUILD_ROOT/opt/ode/man/{man,cat}$i
147+
cp src/ode/man/man$i/*.$i $RPM_BUILD_ROOT/opt/ode/man/man$i
148+
done
149+
cp obj/${context}/ode/man/man1/*.1 $RPM_BUILD_ROOT/opt/ode/man/man1
150+
gzip -9 $RPM_BUILD_ROOT/opt/ode/man/man?/*
151+
152+
cd obj/${context}/ode
153+
for i in server/* bin/* ; do
154+
install -s -m 755 $i/`basename $i` $RPM_BUILD_ROOT/opt/ode/$i
155+
done
156+
install -s -m 755 lib/oxm_relay_tcp $RPM_BUILD_ROOT/opt/ode/lib
157+
158+
cat > $RPM_BUILD_ROOT/usr/bin/workon <<'EOF'
159+
#!/bin/sh
160+
# What this script tries to do is locate the installation
161+
# directory of the ode package and add the appropriate
162+
# paths to the ode executables and man pages. It picks
163+
# up this path from the actual ode package. Once the
164+
# paths have been set, the ``real'' workon executable is
165+
# called. This way, the ode packages are only in your
166+
# path if you are working in the ODE environment.
167+
I="`rpm -q ode --qf '%%{INSTALLPREFIX}\n'`"
168+
MANPATH=$I/man${MANPATH:+':'$MANPATH}
169+
PATH=$I/bin:$PATH
170+
export MANPATH PATH
171+
exec $I/bin/workon $*
172+
EOF
173+
chmod +x $RPM_BUILD_ROOT/usr/bin/workon
174+
175+
mkdir -p $RPM_BUILD_ROOT/opt/ode/doc/{sag,users.gd/common}
176+
find doc -name \*.ps -print | xargs -t gzip -9
177+
178+
/usr/bin/install -m 644 -o root -g root doc/sag/sag.ps.gz ${RPM_BUILD_ROOT}/opt/ode/doc/sag
179+
for x in doc/users.gd/common/*.ps.gz ;
180+
do
181+
/usr/bin/install -m 644 -o root -g root $x ${RPM_BUILD_ROOT}/opt/ode/doc/users.gd/common/
182+
done;
183+
184+
#
185+
# Let's keep the configuration files around in case
186+
# someone wants to use them. They will be stored as examples.
187+
#
188+
189+
mkdir -p $RPM_BUILD_ROOT/opt/ode/share/{ode/mk,rc_files/ode}
190+
cd ../../../
191+
/usr/bin/install -m 644 sandboxrc $RPM_BUILD_ROOT/opt/ode/share/
192+
193+
cd rc_files
194+
for x in projects sets;
195+
do
196+
/usr/bin/install -m 644 $x $RPM_BUILD_ROOT/opt/ode/share/rc_files;
197+
done;
198+
199+
for x in ode/sb.conf ode/sc.conf;
200+
do
201+
/usr/bin/install -m 644 $x $RPM_BUILD_ROOT/opt/ode/share/rc_files/ode;
202+
done;
203+
204+
cd ../src
205+
/usr/bin/install -m 644 Makeconf $RPM_BUILD_ROOT/opt/ode/share/
206+
/usr/bin/install -m 644 Makefile $RPM_BUILD_ROOT/opt/ode/share/
207+
208+
cd ode
209+
/usr/bin/install -m 644 Buildconf $RPM_BUILD_ROOT/opt/ode/share/ode
210+
/usr/bin/install -m 644 Buildconf.exp $RPM_BUILD_ROOT/opt/ode/share/ode
211+
212+
cd mk
213+
for x in osf.depend.mk \
214+
osf.doc.mk \
215+
osf.lib.mk \
216+
osf.lib.mk \
217+
osf.man.mk \
218+
osf.obj.mk \
219+
osf.prog.mk \
220+
osf.rules.mk \
221+
osf.script.mk \
222+
osf.std.mk \
223+
osf.ode.mk \
224+
osf.ode.passes.mk \
225+
sys.mk;
226+
do
227+
/usr/bin/install -m 644 $x $RPM_BUILD_ROOT/opt/ode/share/ode/mk;
228+
done;
229+
230+
#
231+
# That should be everything that people would
232+
# want to have from this distribution.
233+
#
234+
235+
%clean
236+
rm -rf $RPM_BUILD_ROOT
237+
238+
%files
239+
%defattr(-,root,root)
240+
%doc src/README src/README.bin src/README.doc src/README.src src/README.top
241+
%dir /opt/ode
242+
%dir /opt/ode/bin
243+
%dir /opt/ode/man
244+
%dir /opt/ode/man/man1
245+
%dir /opt/ode/man/cat1
246+
/opt/ode/bin/build
247+
/opt/ode/bin/currentsb
248+
/opt/ode/bin/genpath
249+
/opt/ode/bin/make
250+
/opt/ode/bin/makepath
251+
/opt/ode/bin/md
252+
/opt/ode/bin/mklinks
253+
/opt/ode/bin/mksb
254+
/opt/ode/bin/sbinfo
255+
/opt/ode/bin/workon
256+
/opt/ode/man/man1/build.1.gz
257+
/opt/ode/man/man1/currentsb.1.gz
258+
/opt/ode/man/man1/genpath.1.gz
259+
/opt/ode/man/man1/make.1.gz
260+
/opt/ode/man/man1/mklinks.1.gz
261+
/opt/ode/man/man1/mksb.1.gz
262+
/opt/ode/man/man1/sbinfo.1.gz
263+
/opt/ode/man/man1/workon.1.gz
264+
/opt/ode/man/man5
265+
/opt/ode/share
266+
%dir /opt/ode/man/cat5
267+
/usr/bin/workon
268+
269+
%files scontrol
270+
%defattr(-,root,root)
271+
/opt/ode/bin/bci
272+
/opt/ode/bin/bco
273+
/opt/ode/bin/bcreate
274+
/opt/ode/bin/bcs
275+
/opt/ode/bin/bdiff
276+
/opt/ode/bin/blog
277+
/opt/ode/bin/bmerge
278+
/opt/ode/bin/bstat
279+
/opt/ode/bin/bsubmit
280+
/opt/ode/bin/odexm_cli
281+
/opt/ode/bin/release
282+
/opt/ode/bin/resb
283+
/opt/ode/bin/sadmin
284+
/opt/ode/bin/sup
285+
/opt/ode/bin/upgrade
286+
/opt/ode/bin/uptodate
287+
/opt/ode/man/man1/bci.1.gz
288+
/opt/ode/man/man1/bco.1.gz
289+
/opt/ode/man/man1/bcreate.1.gz
290+
/opt/ode/man/man1/bcs.1.gz
291+
/opt/ode/man/man1/bcsfileoptions.1.gz
292+
/opt/ode/man/man1/bcsoptions.1.gz
293+
/opt/ode/man/man1/bdelta.1.gz
294+
/opt/ode/man/man1/bdiff.1.gz
295+
/opt/ode/man/man1/blog.1.gz
296+
/opt/ode/man/man1/bmerge.1.gz
297+
/opt/ode/man/man1/bstat.1.gz
298+
/opt/ode/man/man1/bsubmit.1.gz
299+
/opt/ode/man/man1/no_ch_file_opts.1.gz
300+
/opt/ode/man/man1/no_sv_file_opts.1.gz
301+
/opt/ode/man/man1/release.1.gz
302+
/opt/ode/man/man1/resb.1.gz
303+
/opt/ode/man/man1/sadmin.1.gz
304+
/opt/ode/man/man1/sup.1.gz
305+
/opt/ode/man/man1/uptodate.1.gz
306+
/opt/ode/lib
307+
/opt/ode/man/man8
308+
%dir /opt/ode/man/cat8
309+
/opt/ode/server
310+
311+
%files psdocs
312+
%defattr(-,root,root)
313+
/opt/ode/doc/

0 commit comments

Comments
 (0)