author | chrisk |
Mon, 31 Aug 2009 16:23:04 +0000 | |
changeset 16434 | f21f22550fe9 |
parent 16431 | d7743d81b302 |
child 17842 | 1cc615f41f16 |
permissions | -rw-r--r-- |
9397 | 1 |
# |
2 |
# spec file for package SUNWopensp |
|
3 |
# |
|
4 |
# includes module(s): OpenSP |
|
5 |
# |
|
6 |
# Copyright (c) 2003 Sun Microsystems, Inc. |
|
7 |
# This file and all modifications and additions to the pristine |
|
8 |
# package are under the same license as the package itself. |
|
9 |
# |
|
16434 | 10 |
%define owner laca |
9397 | 11 |
# |
12 |
%include Solaris.inc |
|
16431 | 13 |
|
14 |
%define OSR delivered in s10:0 |
|
15 |
||
9397 | 16 |
Name: SUNWopensp |
17 |
Summary: The OpenJade group's SGML and XML parsing tools |
|
18 |
Version: 1.5.1 |
|
19 |
SUNW_BaseDir: %{_basedir} |
|
11965 | 20 |
SUNW_Copyright: %{name}.copyright |
9397 | 21 |
BuildRoot: %{_tmppath}/%{name}-%{version}-build |
22 |
Source: http://easynews.dl.sourceforge.net/sourceforge/openjade/OpenSP-%{version}.tar.gz |
|
23 |
Source1: l10n-configure.sh |
|
24 |
# date:2004-01-09 type:feature owner:laca |
|
25 |
# marking as a feature patch because upstream development stopped years ago |
|
15188
f00d2aae4481
* SUNWopensp.spec: Manpage patch for ATTRIBUTES, ARC comments and shadow
mattman
parents:
12031
diff
changeset
|
26 |
Patch1: opensp-01-forte.diff |
f00d2aae4481
* SUNWopensp.spec: Manpage patch for ATTRIBUTES, ARC comments and shadow
mattman
parents:
12031
diff
changeset
|
27 |
# date:2009-02-20 type:branding owner:mattman |
f00d2aae4481
* SUNWopensp.spec: Manpage patch for ATTRIBUTES, ARC comments and shadow
mattman
parents:
12031
diff
changeset
|
28 |
Patch2: opensp-02-manpages.diff |
9397 | 29 |
Requires: SUNWlibC |
30 |
%include default-depend.inc |
|
31 |
||
32 |
%package devel |
|
33 |
Summary: %{summary} - development files |
|
34 |
SUNW_BaseDir: /usr |
|
35 |
%include default-depend.inc |
|
36 |
||
37 |
%package root |
|
38 |
Summary: %{summary} - / filesystem |
|
39 |
SUNW_BaseDir: / |
|
40 |
%include default-depend.inc |
|
41 |
||
42 |
%prep |
|
43 |
%setup -q -n OpenSP-%{version} |
|
15188
f00d2aae4481
* SUNWopensp.spec: Manpage patch for ATTRIBUTES, ARC comments and shadow
mattman
parents:
12031
diff
changeset
|
44 |
%patch1 -p1 -b .forte |
f00d2aae4481
* SUNWopensp.spec: Manpage patch for ATTRIBUTES, ARC comments and shadow
mattman
parents:
12031
diff
changeset
|
45 |
%patch2 -p1 |
9397 | 46 |
|
47 |
%define INSTALL install -m 755 -s |
|
48 |
%define INSTALL_DIR install -d -m 755 |
|
49 |
%define INSTALL_DATA install -m 644 |
|
50 |
%define orig_name opensp |
|
51 |
%define sgml_dir %{_datadir}/sgml |
|
52 |
%define sgml_dir_pkg %{sgml_dir}/%{orig_name} |
|
53 |
%define sgml_var_dir /var/lib/sgml |
|
54 |
||
12012 | 55 |
bash -x %SOURCE1 --enable-sun-linguas |
9397 | 56 |
|
57 |
%build |
|
58 |
CPUS=`/usr/sbin/psrinfo | grep on-line | wc -l | tr -d ' '` |
|
59 |
if test "x$CPUS" = "x" -o $CPUS = 0; then |
|
60 |
CPUS=1 |
|
61 |
fi |
|
62 |
%if %cc_is_gcc |
|
63 |
%else |
|
64 |
export CXX="${CXX} -norunpath" |
|
65 |
%endif |
|
66 |
export CXXFLAGS="%cxx_optflags" |
|
67 |
export LDFLAGS="-z ignore" |
|
68 |
export CFLAGS="%optflags" |
|
69 |
aclocal |
|
70 |
automake -f -c |
|
12031 | 71 |
|
72 |
%if %build_l10n |
|
73 |
bash -x %SOURCE1 --enable-copyright |
|
74 |
%endif |
|
75 |
||
9397 | 76 |
libtoolize --copy --force |
77 |
autoconf --force |
|
78 |
./configure --prefix=%{_prefix} \ |
|
79 |
--datadir=%{_datadir} \ |
|
80 |
--libdir=%{_libdir} \ |
|
81 |
--mandir=%{_mandir} \ |
|
82 |
--localstatedir=%{_localstatedir} \ |
|
83 |
--with-gnu-ld \ |
|
84 |
--disable-http \ |
|
85 |
--disable-nls \ |
|
86 |
--enable-default-catalog="CATALOG:/etc/sgml/catalog:%{sgml_dir}/CATALOG" |
|
87 |
make -j$CPUS |
|
88 |
perl -pi -e 's/sx/sgml2xml/g; s/SX/SGML2XML/g;' doc/sx.htm |
|
89 |
perl -pi -e 's/>sx/>sgml2xml/g; s/>SX/>SGML2XML/g;' doc/{new,index}.htm |
|
90 |
||
91 |
%install |
|
92 |
[ "$RPM_BUILD_ROOT" != "" ] && [ -d $RPM_BUILD_ROOT ] && rm -rf $RPM_BUILD_ROOT |
|
93 |
%{INSTALL_DIR} $RPM_BUILD_ROOT%{_libdir} |
|
94 |
# %{INSTALL_DIR} $RPM_BUILD_ROOT%{_includedir}/opensp |
|
95 |
make install DESTDIR=$RPM_BUILD_ROOT |
|
96 |
make install-man DESTDIR=$RPM_BUILD_ROOT |
|
97 |
pushd $RPM_BUILD_ROOT%{_bindir} |
|
98 |
for b in os* onsgmls; do |
|
99 |
ln -sf ${b} ${b#o} |
|
100 |
done |
|
101 |
# avoid conflict with rzsz package |
|
102 |
rm -f sx |
|
103 |
ln -sf osx s2x |
|
104 |
ln -sf osx sgml2xml |
|
105 |
ln -sf osx osgml2xml |
|
106 |
popd |
|
107 |
%{INSTALL_DIR} $RPM_BUILD_ROOT%{sgml_dir_pkg} |
|
108 |
{ |
|
109 |
for c in opensp-implied.dcl japan.dcl xml.dcl; do |
|
110 |
%{INSTALL_DATA} pubtext/$c $RPM_BUILD_ROOT%{sgml_dir_pkg}/$c |
|
111 |
echo "-- SGMLDECL \"%{sgml_dir_pkg}/$c\" --" |
|
112 |
done |
|
113 |
} > CATALOG.opensp |
|
114 |
sed 's|decl|dcl|' pubtext/xml.soc > $RPM_BUILD_ROOT%{sgml_dir_pkg}/xml.soc |
|
115 |
%{INSTALL_DIR} $RPM_BUILD_ROOT%{sgml_var_dir} |
|
116 |
%{INSTALL_DATA} CATALOG.opensp $RPM_BUILD_ROOT%{sgml_var_dir} |
|
117 |
ln -sf ../../../../%{sgml_var_dir}/CATALOG.opensp \ |
|
118 |
$RPM_BUILD_ROOT%{sgml_dir}/CATALOG.opensp |
|
119 |
rm -fr html |
|
120 |
mkdir html |
|
121 |
cp doc/catalog doc/*htm html |
|
122 |
%define DOCFILES COPYING README NEWS AUTHORS ABOUT-NLS |
|
123 |
{ |
|
124 |
echo "<html><head><title>OpenSP documentation directory</title></head>" |
|
125 |
echo "<body>" |
|
126 |
for f in %{DOCFILES}; do |
|
127 |
[ -f $f ] || continue |
|
128 |
echo "<a href=\"$f\">$f</a>" |
|
129 |
done |
|
130 |
echo "<a href=\"html/index.htm\">OpenSP</a>, official documentation (html)" |
|
131 |
} >index.html |
|
132 |
||
133 |
rm -f $RPM_BUILD_ROOT%{_libdir}/lib*a |
|
134 |
rm -rf $RPM_BUILD_ROOT%{_datadir}/OpenSP |
|
135 |
rm -rf $RPM_BUILD_ROOT%{_datadir}/doc |
|
136 |
rm -rf $RPM_BUILD_ROOT%{_prefix}/doc |
|
137 |
||
138 |
%{?pkgbuild_postprocess: %pkgbuild_postprocess -v -c "%{version}:%{jds_version}:%{name}:$RPM_ARCH:%(date +%%Y-%%m-%%d):%{support_level}" $RPM_BUILD_ROOT} |
|
139 |
||
140 |
%clean |
|
141 |
rm -rf $RPM_BUILD_ROOT |
|
142 |
||
143 |
%files |
|
144 |
%defattr (-, root, bin) |
|
145 |
%dir %attr (0755, root, bin) %{_bindir} |
|
146 |
%{_bindir}/*nsgmls |
|
147 |
%{_bindir}/*sgmlnorm |
|
148 |
%{_bindir}/*spcat |
|
149 |
%{_bindir}/*spam |
|
150 |
%{_bindir}/*spent |
|
151 |
%{_bindir}/osx |
|
152 |
%{_bindir}/*s2x |
|
153 |
%{_bindir}/*sgml2xml |
|
154 |
%dir %attr (0755, root, bin) %{_libdir} |
|
155 |
%{_libdir}/lib*.so.* |
|
156 |
%{_libdir}/lib*.so |
|
157 |
%dir %attr (0755, root, sys) %{_datadir} |
|
158 |
%dir %attr (0755, root, bin) %{_mandir} |
|
159 |
%dir %attr (0755, root, bin) %{_mandir}/man1 |
|
160 |
%{_mandir}/man1/* |
|
161 |
%{sgml_dir_pkg} |
|
162 |
%{sgml_dir}/CATALOG.opensp |
|
163 |
||
164 |
%files devel |
|
165 |
%defattr (-, root, bin) |
|
166 |
%dir %attr (0755, root, bin) %{_includedir} |
|
167 |
%{_includedir}/OpenSP |
|
168 |
||
169 |
%files root |
|
170 |
%defattr (-, root, sys) |
|
171 |
%dir %attr (0755, root, sys) /var |
|
172 |
%dir %attr (0755, root, other) /var/lib |
|
173 |
%{sgml_var_dir}/CATALOG.opensp |
|
174 |
||
175 |
%changelog |
|
15188
f00d2aae4481
* SUNWopensp.spec: Manpage patch for ATTRIBUTES, ARC comments and shadow
mattman
parents:
12031
diff
changeset
|
176 |
* Fri Feb 20 2009 - [email protected] |
f00d2aae4481
* SUNWopensp.spec: Manpage patch for ATTRIBUTES, ARC comments and shadow
mattman
parents:
12031
diff
changeset
|
177 |
- Add manpage page patch, adds ATTRIBUTES and ARC comments to existing pages |
f00d2aae4481
* SUNWopensp.spec: Manpage patch for ATTRIBUTES, ARC comments and shadow
mattman
parents:
12031
diff
changeset
|
178 |
- Remove sym-linking of manpages and create shadow pages instead. |
9397 | 179 |
* Sun Jun 11 2006 - [email protected] |
180 |
- change group from other to bin/sys |
|
181 |
* Wed May 10 2006 - [email protected] |
|
182 |
- merge -share pkg(s) into the base pkg(s) |
|
183 |
- move to /usr |
|
184 |
* Fri Feb 17 2006 - [email protected] |
|
185 |
- Update Build/Requires after running check-deps.pl script. |
|
186 |
* Fri Sep 02 2005 - [email protected] |
|
187 |
- remove unpackaged files |
|
188 |
* Sat Oct 02 2004 - [email protected] |
|
189 |
- moved to /usr/sfw |
|
190 |
- added %pkgbuild_postprocess |
|
191 |
* Sat Oct 02 2004 - [email protected] |
|
192 |
- move to /usr/sfw |
|
193 |
* Mon Aug 30 2004 - [email protected] |
|
194 |
- Bug 5091588 : include files should be in a separate devel package |
|
195 |
* Tue Jun 22 2004 - [email protected] |
|
196 |
- changed install location to /usr/lib and /usr/bin |
|
197 |
* Tue Jun 1 2004 - [email protected] |
|
198 |
- fix broken symlinks |
|
199 |
* Sun Apr 18 2004 - [email protected] |
|
200 |
- Set correct permissions on %_includedir |
|
201 |
* Sat Feb 28 2004 - [email protected] |
|
202 |
- use cxx_optflags |
|
203 |
* Mon Jan 26 2004 - [email protected] |
|
204 |
- initial version added to CVS |