5eab4f
%global xmlxsdver 2009/01
5eab4f
5eab4f
Name: sgml-common
5eab4f
Version: 0.6.3
5eab4f
Release: 39%{?dist}
5eab4f
Group: Applications/Text
5eab4f
5eab4f
Summary: Common SGML catalog and DTD files
5eab4f
5eab4f
License: GPL+
5eab4f
5eab4f
BuildArch: noarch
5eab4f
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
5eab4f
5eab4f
#Actually - there is no homepage of this project, on that URL
5eab4f
#page you could get complete ISO 8879 listing as was on the
5eab4f
#old page - only part of it is included in sgml-common package.
5eab4f
URL: http://www.w3.org/2003/entities/
5eab4f
5eab4f
Source0: ftp://sources.redhat.com/pub/docbook-tools/new-trials/SOURCES/%{name}-%{version}.tgz
5eab4f
# Following 4 from openjade/pubtext - same maintainer as in SGML-common, so up2date:
5eab4f
Source1: xml.dcl
5eab4f
Source2: xml.soc
5eab4f
Source3: html.dcl
5eab4f
Source4: html.soc
5eab4f
Source5: http://www.w3.org/%{xmlxsdver}/xml.xsd
5eab4f
5eab4f
Patch0: sgml-common-umask.patch
5eab4f
Patch1: sgml-common-xmldir.patch
5eab4f
Patch2: sgml-common-quotes.patch
5eab4f
5eab4f
BuildRequires: libxml2
5eab4f
BuildRequires: automake
5eab4f
Requires: /bin/basename
5eab4f
5eab4f
%description
5eab4f
The sgml-common package contains a collection of entities and DTDs
5eab4f
that are useful for processing SGML, but that don't need to be
5eab4f
included in multiple packages.  Sgml-common also includes an
5eab4f
up-to-date Open Catalog file.
5eab4f
5eab4f
%package -n xml-common
5eab4f
Group: Applications/Text
5eab4f
Summary: Common XML catalog and DTD files
5eab4f
License: GPL+
5eab4f
Requires(pre): %{_bindir}/xmlcatalog
5eab4f
5eab4f
%description -n xml-common
5eab4f
The xml-common is a subpackage of sgml-common which contains
5eab4f
a collection XML catalogs that are useful for processing XML,
5eab4f
but that don't need to be included in main package.
5eab4f
5eab4f
%prep
5eab4f
%setup -q
5eab4f
%patch0 -p1 -b .umask
5eab4f
%patch1 -p1 -b .xmldir
5eab4f
%patch2 -p1 -b .quotes
5eab4f
5eab4f
# replace bogus links with files
5eab4f
automakedir=`ls -1d /usr/share/automake* | head -n +1`
5eab4f
for file in COPYING INSTALL install-sh missing mkinstalldirs; do
5eab4f
   rm $file
5eab4f
   cp -p $automakedir/$file .
5eab4f
done
5eab4f
5eab4f
%build
5eab4f
%configure
5eab4f
5eab4f
%install
5eab4f
rm -rf $RPM_BUILD_ROOT
5eab4f
make install DESTDIR="$RPM_BUILD_ROOT" htmldir='%{_datadir}/doc' INSTALL='install -p'
5eab4f
mkdir $RPM_BUILD_ROOT%{_sysconfdir}/xml
5eab4f
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/sgml/docbook
5eab4f
mkdir -p $RPM_BUILD_ROOT%{_datadir}/sgml/docbook
5eab4f
# Touch SGML catalog
5eab4f
touch $RPM_BUILD_ROOT%{_sysconfdir}/sgml/catalog
5eab4f
# Create an empty XML catalog.
5eab4f
XMLCATALOG=$RPM_BUILD_ROOT%{_sysconfdir}/xml/catalog
5eab4f
%{_bindir}/xmlcatalog --noout --create $XMLCATALOG
5eab4f
# ...and add xml.xsd in it
5eab4f
for type in system uri ; do
5eab4f
	for path in 2001 %{xmlxsdver} ; do
5eab4f
		%{_bindir}/xmlcatalog --noout --add $type \
5eab4f
			"http://www.w3.org/$path/xml.xsd" \
5eab4f
			"file://%{_datadir}/xml/xml.xsd" $XMLCATALOG
5eab4f
	done
5eab4f
done
5eab4f
# Now put the common DocBook entries in it
5eab4f
%{_bindir}/xmlcatalog --noout --add "delegatePublic" \
5eab4f
	"-//OASIS//ENTITIES DocBook XML" \
5eab4f
	"file://%{_sysconfdir}/sgml/docbook/xmlcatalog" $XMLCATALOG
5eab4f
%{_bindir}/xmlcatalog --noout --add "delegatePublic" \
5eab4f
	"-//OASIS//DTD DocBook XML" \
5eab4f
	"file://%{_sysconfdir}/sgml/docbook/xmlcatalog" $XMLCATALOG
5eab4f
%{_bindir}/xmlcatalog --noout --add "delegatePublic" \
5eab4f
	"ISO 8879:1986" \
5eab4f
	"file://%{_sysconfdir}/sgml/docbook/xmlcatalog" $XMLCATALOG
5eab4f
%{_bindir}/xmlcatalog --noout --add "delegateSystem" \
5eab4f
	"http://www.oasis-open.org/docbook/" \
5eab4f
	"file://%{_sysconfdir}/sgml/docbook/xmlcatalog" $XMLCATALOG
5eab4f
%{_bindir}/xmlcatalog --noout --add "delegateURI" \
5eab4f
	"http://www.oasis-open.org/docbook/" \
5eab4f
	"file://%{_sysconfdir}/sgml/docbook/xmlcatalog" $XMLCATALOG
5eab4f
# Also create the common DocBook catalog
5eab4f
%{_bindir}/xmlcatalog --noout --create \
5eab4f
	$RPM_BUILD_ROOT%{_sysconfdir}/sgml/docbook/xmlcatalog
5eab4f
ln -sf %{_sysconfdir}/sgml/docbook/xmlcatalog\
5eab4f
	$RPM_BUILD_ROOT%{_datadir}/sgml/docbook/xmlcatalog
5eab4f
5eab4f
rm -f $RPM_BUILD_ROOT%{_datadir}/sgml/xml.dcl
5eab4f
install -p -m0644 %{SOURCE1} %{SOURCE2} %{SOURCE3} %{SOURCE4} \
5eab4f
	$RPM_BUILD_ROOT%{_datadir}/sgml
5eab4f
rm -rf $RPM_BUILD_ROOT%{_datadir}/xml/*
5eab4f
install -p -m0644 %{SOURCE5} $RPM_BUILD_ROOT%{_datadir}/xml
5eab4f
5eab4f
# remove installed doc file and prepare installation with %%doc
5eab4f
rm $RPM_BUILD_ROOT%{_datadir}/doc/*.html
5eab4f
rm -rf __dist_doc/html/
5eab4f
mkdir -p __dist_doc/html/
5eab4f
cp -p doc/HTML/*.html __dist_doc/html/
5eab4f
5eab4f
5eab4f
%clean
5eab4f
rm -rf $RPM_BUILD_ROOT
5eab4f
5eab4f
%pre -n xml-common
5eab4f
if [ $1 -gt 1 ] && [ -e %{_sysconfdir}/xml/catalog ]; then
5eab4f
	for type in system uri ; do
5eab4f
		for path in 2001 %{xmlxsdver} ; do
5eab4f
			%{_bindir}/xmlcatalog --noout --add $type \
5eab4f
				"http://www.w3.org/$path/xml.xsd" \
5eab4f
				"file://%{_datadir}/xml/xml.xsd" \
5eab4f
				%{_sysconfdir}/xml/catalog
5eab4f
		done
5eab4f
	done
5eab4f
fi
5eab4f
5eab4f
%files
5eab4f
%defattr (-,root,root, -)
5eab4f
%doc __dist_doc/html/ AUTHORS NEWS ChangeLog COPYING README
5eab4f
%dir %{_sysconfdir}/sgml
5eab4f
%config(noreplace) %{_sysconfdir}/sgml/sgml.conf
5eab4f
%ghost %verify(not md5 size mtime) %config(noreplace,missingok) %{_sysconfdir}/sgml/catalog
5eab4f
%dir %{_datadir}/sgml
5eab4f
%dir %{_datadir}/sgml/sgml-iso-entities-8879.1986
5eab4f
%{_datadir}/sgml/sgml-iso-entities-8879.1986/*
5eab4f
%{_datadir}/sgml/xml.dcl
5eab4f
%{_datadir}/sgml/xml.soc
5eab4f
%{_datadir}/sgml/html.dcl
5eab4f
%{_datadir}/sgml/html.soc
5eab4f
%{_bindir}/sgmlwhich
5eab4f
%{_bindir}/install-catalog
5eab4f
%{_mandir}/man8/install-catalog.8*
5eab4f
5eab4f
%files -n xml-common
5eab4f
%defattr (-,root,root,-)
5eab4f
%doc AUTHORS NEWS ChangeLog COPYING README
5eab4f
%dir %{_sysconfdir}/xml
5eab4f
%dir %{_sysconfdir}/sgml/docbook
5eab4f
%config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/xml/catalog
5eab4f
%config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/sgml/docbook/xmlcatalog
5eab4f
%dir %{_datadir}/sgml
5eab4f
%dir %{_datadir}/sgml/docbook
5eab4f
%{_datadir}/sgml/docbook/xmlcatalog
5eab4f
%dir %{_datadir}/xml
5eab4f
%{_datadir}/xml/xml.xsd
5eab4f
5eab4f
%changelog
5eab4f
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 0.6.3-39
5eab4f
- Mass rebuild 2013-12-27
5eab4f
5eab4f
* Thu Oct 11 2012 Ondrej Vasik <ovasik@redhat.com> 0.6.3-38
5eab4f
- get rid of the explicit automake14 requirement
5eab4f
5eab4f
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.3-37
5eab4f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
5eab4f
5eab4f
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.3-36
5eab4f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
5eab4f
5eab4f
* Sun Oct 30 2011 Ville Skyttä <ville.skytta@iki.fi> - 0.6.3-35
5eab4f
- Include xml.xsd in xml-common (#750073).
5eab4f
5eab4f
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.3-34
5eab4f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
5eab4f
5eab4f
* Mon Jul 12 2010 Ondrej Vasik <ovasik@redhat.com> 0.6.3-33
5eab4f
- ship COPYING file with both sgml-common and xml-common
5eab4f
- ship documentation with xml-common
5eab4f
5eab4f
* Fri Jan 14 2010 Ondrej Vasik <ovasik@redhat.com> 0.6.3-32
5eab4f
- Merge review #226415: remove unapplied patches, remove
5eab4f
  versioned BR
5eab4f
5eab4f
* Wed Nov 11 2009 Ondrej Vasik <ovasik@redhat.com> 0.6.3-31
5eab4f
- apply quotes patch once again (accidently deleted in Nov07-#533058)
5eab4f
5eab4f
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.3-30
5eab4f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
5eab4f
5eab4f
* Thu May 28 2009 Ondrej Vasik <ovasik@redhat.com> 0.6.3-29
5eab4f
- do own /etc/sgml/catalog
5eab4f
5eab4f
* Tue May 19 2009 Ondrej Vasik <ovasik@redhat.com> 0.6.3-28
5eab4f
- do not provide explicit url for xml-common subpackage,
5eab4f
  fix trailing spaces
5eab4f
- add Requires: /bin/basename (#501360)
5eab4f
5eab4f
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.3-27
5eab4f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
5eab4f
5eab4f
* Thu Aug 07 2008 Ondrej Vasik <ovasik@redhat.com> 0.6.3-26
5eab4f
- /etc/sgml/docbook dir now owned by package(#458230)
5eab4f
- get rid off fuzz in patches
5eab4f
5eab4f
* Tue Jul 01 2008 Ondrej Vasik <ovasik@redhat.com> 0.6.3-25
5eab4f
- mark xmlcatalog config(noreplace) to prevent overwriting
5eab4f
  of the content, move it to sysconfdir and make symlink for
5eab4f
  it to silence rpmlint
5eab4f
5eab4f
* Mon Jun 30 2008 Ondrej Vasik <ovasik@redhat.com> 0.6.3-24
5eab4f
- mark catalog files as (not md5 size mtime) for verify to
5eab4f
  prevent info about changed files (#453271)
5eab4f
5eab4f
* Thu Nov 22 2007 Ondrej Vasik <ovasik@redhat.com> 0.6.3-23
5eab4f
- Another MergeReview improvements(provided by Patrice Dumas)
5eab4f
- copy Automake-1.4 files instead of rerunning autotools,
5eab4f
- better preserving timestamps, better handling of documentation
5eab4f
- improved XML-common description
5eab4f
5eab4f
* Thu Nov 15 2007 Ondrej Vasik <ovasik@redhat.com> 0.6.3-22
5eab4f
- Merge Review(226415)
5eab4f
- changed: License Tag, using RPM macros instead of hardcoded
5eab4f
  dirs, summary ended with dot, added URL, removed CHANGES
5eab4f
  file as obsolete, preserved timestamps and some other cosmetic
5eab4f
  changes
5eab4f
- no longer shipping old automake tarball, fixed issue with man8_DATA,
5eab4f
  BuildRequire:Automake,Autoconf again(see MergeReview discussion)
5eab4f
5eab4f
* Mon May 28 2007 Ondrej Vasik <ovasik@redhat.com> 0.6.3-21
5eab4f
- Fixed broken URL (changed to XML entity declarations) (bug #237726)
5eab4f
- Rebuilt
5eab4f
5eab4f
* Tue May 15 2007 Tim Waugh <twaugh@redhat.com> 0.6.3-20
5eab4f
- Added dist tag.
5eab4f
- Fixed summary.
5eab4f
- Removed build dependency on autoconf/automake.
5eab4f
5eab4f
* Tue Oct 24 2006 Tim Waugh <twaugh@redhat.com> 0.6.3-19
5eab4f
- Removed stale URL (bug #210848).
5eab4f
5eab4f
* Mon Jun 12 2006 Tim Waugh <twaugh@redhat.com> 0.6.3-18
5eab4f
- Build requires automake and autoconf (bug #194709).
5eab4f
5eab4f
* Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com>
5eab4f
- rebuilt
5eab4f
5eab4f
* Wed Sep 22 2004 Than Ngo <than@redhat.com> 0.6.3-17
5eab4f
- rebuilt
5eab4f
5eab4f
* Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
5eab4f
- rebuilt
5eab4f
5eab4f
* Mon Dec  8 2003 Tim Waugh <twaugh@redhat.com> 0.6.3-15
5eab4f
- Patch from Ville Skyttä <ville.skytta@iki.fi> (bug #111625):
5eab4f
  - Include /usr/share/xml in xml-common.
5eab4f
  - Own /usr/share/sgml and /usr/share/xml.
5eab4f
5eab4f
* Wed Jan 22 2003 Tim Powers <timp@redhat.com>
5eab4f
- rebuilt
5eab4f
5eab4f
* Wed Oct 23 2002 Tim Waugh <twaugh@redhat.com> 0.6.3-13
5eab4f
- Ship the installed documentation.
5eab4f
- Don't install files not packaged.
5eab4f
5eab4f
* Fri Jun 21 2002 Tim Powers <timp@redhat.com>
5eab4f
- automated rebuild
5eab4f
5eab4f
* Thu May 23 2002 Tim Powers <timp@redhat.com>
5eab4f
- automated rebuild
5eab4f
5eab4f
* Wed Apr 24 2002 Tim Waugh <twaugh@redhat.com> 0.6.3-10
5eab4f
- Ship {xml,html}.{dcl,soc} (bug #63500, bug #62980).
5eab4f
- Work around broken tarball packaging.
5eab4f
5eab4f
* Thu Feb 21 2002 Tim Waugh <twaugh@redhat.com> 0.6.3-9
5eab4f
- Rebuild in new environment.
5eab4f
5eab4f
* Thu Jan 17 2002 Tim Waugh <twaugh@redhat.com> 0.6.3-8
5eab4f
- Back to /usr/share/sgml.  Now install docbook-dtds.
5eab4f
- Use a real install-sh, not the symlink shipped in the tarball.
5eab4f
5eab4f
* Wed Jan 09 2002 Tim Powers <timp@redhat.com> 0.6.3-7
5eab4f
- automated rebuild
5eab4f
5eab4f
* Mon Nov  5 2001 Tim Waugh <twaugh@redhat.com> 0.6.3-6
5eab4f
- Don't create a useless empty catalog.
5eab4f
- Don't try to put install things outside the build root.
5eab4f
- Build requires a libxml2 that actually works.
5eab4f
5eab4f
* Mon Nov  5 2001 Tim Waugh <twaugh@redhat.com> 0.6.3-4
5eab4f
- Use (and handle) catalog files with quotes in install-catalog.
5eab4f
5eab4f
* Thu Nov  1 2001 Tim Waugh <twaugh@redhat.com> 0.6.3-3
5eab4f
- Create default XML Catalog at build time, not install time.
5eab4f
5eab4f
* Fri Oct  5 2001 Tim Waugh <twaugh@redhat.com> 0.6.3-2
5eab4f
- Move XML things into /usr/share/xml, and split them out into separate
5eab4f
  xml-common package.
5eab4f
5eab4f
* Mon Oct  1 2001 Tim Waugh <twaugh@redhat.com> 0.6.3-1
5eab4f
- 0.6.3.  Incorporates oldsyntax and quiet patches.
5eab4f
- Make /etc/sgml/sgml.conf noreplace.
5eab4f
- Own /etc/sgml, various other directories (bug #47485, bug #54180).
5eab4f
5eab4f
* Wed May 23 2001 Tim Waugh <twaugh@redhat.com> 0.5-7
5eab4f
- Remove execute bit from data files.
5eab4f
5eab4f
* Mon May 21 2001 Tim Waugh <twaugh@redhat.com> 0.5-6
5eab4f
- install-catalog needs to make sure that it creates world-readable files
5eab4f
  (bug #41552).
5eab4f
5eab4f
* Wed Mar 14 2001 Tim Powers <timp@redhat.com> 0.5-5
5eab4f
- fixed license
5eab4f
5eab4f
* Wed Jan 24 2001 Tim Waugh <twaugh@redhat.com>
5eab4f
- Make install-catalog quieter during normal operation.
5eab4f
5eab4f
* Tue Jan 23 2001 Tim Waugh <twaugh@redhat.com>
5eab4f
- Require textutils, fileutils, grep (bug #24719).
5eab4f
5eab4f
* Wed Jan 17 2001 Tim Waugh <twaugh@redhat.com>
5eab4f
- Require sh-utils.
5eab4f
5eab4f
* Mon Jan 15 2001 Tim Waugh <twaugh@redhat.com>
5eab4f
- Don't play so many macro games.
5eab4f
- Fix typo in install-catalog patch.
5eab4f
5eab4f
* Mon Jan 08 2001 Tim Waugh <twaugh@redhat.com>
5eab4f
- Change group.
5eab4f
- Install by hand (man/en/...).  Use %%{_mandir}.
5eab4f
- Use %%{_tmppath}.
5eab4f
- Make install-catalog fail silently if given the old syntax.
5eab4f
- Add CHANGES file.
5eab4f
- Change Copyright: to License:.
5eab4f
- Remove Packager: line.
5eab4f
5eab4f
* Mon Jan 08 2001 Tim Waugh <twaugh@redhat.com>
5eab4f
- Based on Eric Bischoff's new-trials packages.