Poky Project Discussions
 help / color / mirror / Atom feed
From: Joshua Lock <josh@openedhand.com>
To: poky@yoctoproject.org
Subject: Re: [PATCH 1/9] sgml-common: new recipe v0.6.3
Date: Fri, 28 Jan 2011 15:26:55 +0000	[thread overview]
Message-ID: <1296228416.2704.17.camel@scimitar> (raw)
In-Reply-To: <2d59c34ceb4fb3a9c80bfcce999172ae6c16e663.1296167950.git.scott.a.garman@intel.com>

On Thu, 2011-01-27 at 14:42 -0800, Scott Garman wrote:
> From: Scott Garman <scott.a.garman@intel.com>
> 
> Recipe derived from OpenEmbedded.
> 
> Signed-off-by: Scott Garman <scott.a.garman@intel.com>
> ---
>  .../sgml-common/sgml-common-0.6.3/autohell.patch   |   58 ++++++++++++++++++++
>  .../sgml-common/sgml-common-native_0.6.3.bb        |   50 +++++++++++++++++
>  .../sgml-common/sgml-common_0.6.3.bb               |   53 ++++++++++++++++++
>  3 files changed, 161 insertions(+), 0 deletions(-)
>  create mode 100644 meta/recipes-devtools/sgml-common/sgml-common-0.6.3/autohell.patch
>  create mode 100644 meta/recipes-devtools/sgml-common/sgml-common-native_0.6.3.bb
>  create mode 100644 meta/recipes-devtools/sgml-common/sgml-common_0.6.3.bb
> 
> diff --git a/meta/recipes-devtools/sgml-common/sgml-common-0.6.3/autohell.patch b/meta/recipes-devtools/sgml-common/sgml-common-0.6.3/autohell.patch
> new file mode 100644
> index 0000000..1366ada
> --- /dev/null
> +++ b/meta/recipes-devtools/sgml-common/sgml-common-0.6.3/autohell.patch
> @@ -0,0 +1,58 @@
> +Patch obtained from OpenEmbedded.
> +
> +Signed-off-by: Scott Garman <scott.a.garman@intel.com>
> +--- sgml-common-0.6.3/bin/Makefile.am~autohell.patch	2001-01-30 15:42:21.000000000 +0100
> ++++ sgml-common-0.6.3/bin/Makefile.am	2004-06-17 11:51:11.000000000 +0200
> +@@ -1,6 +1,5 @@
> + primitive_scripts = sgmlwhich
> + 
> +-bindir = $(prefix)/bin
> + bin_SCRIPTS = install-catalog $(primitive_scripts)
> + 
> + EXTRA_DIST =  install-catalog.in $(primitive_scripts)
> +--- /dev/null	2003-09-23 19:59:22.000000000 +0200
> ++++ sgml-common-0.6.3/bin/sgmlwhich.in	2004-06-17 11:51:11.000000000 +0200
> +@@ -0,0 +1,7 @@
> ++#!/bin/sh
> ++# Location of the main configuration file for consistency with non-LSB platforms
> ++# Send any comments to Eric Bischoff <eric@caldera.de>
> ++# This program is under GPL license. See LICENSE file for details.
> ++
> ++echo "@sysconfdir@/sgml/sgml.conf"
> ++# Simple, isn't it? ;-)
> +--- /dev/null	2003-09-23 19:59:22.000000000 +0200
> ++++ sgml-common-0.6.3/config/sgml.conf.in	2004-06-17 11:51:11.000000000 +0200
> +@@ -0,0 +1,2 @@
> ++SGML_BASE_DIR=@datadir@/sgml
> ++SGML_CATALOGS_DIR=@sysconfdir@/sgml
> +--- sgml-common-0.6.3/configure.in~autohell.patch	2001-05-25 18:40:54.000000000 +0200
> ++++ sgml-common-0.6.3/configure.in	2004-06-17 11:53:22.000000000 +0200
> +@@ -3,11 +3,6 @@
> + 
> + AM_INIT_AUTOMAKE(sgml-common, 0.6.3)
> + 
> +-docdir='$(prefix)/doc'
> +-AC_SUBST(docdir)
> +-
> +-dnl Checks for programs.
> +-
> + dnl Checks for libraries.
> + 
> + dnl Checks for header files.
> +@@ -18,6 +13,5 @@
> + 
> + AC_OUTPUT(Makefile \
> +           bin/Makefile bin/install-catalog \
> +-          config/Makefile \
> +-          doc/Makefile doc/HTML/Makefile doc/man/Makefile doc/refentry/Makefile \
> ++          config/Makefile config/sgml.conf bin/sgmlwhich \
> +           sgml-iso-entities/Makefile xml-iso-entities/Makefile)
> +
> +--- sgml-common-0.6.3/Makefile.am~no-docs	2001-05-25 18:22:01.000000000 +0200
> ++++ sgml-common-0.6.3/Makefile.am	2004-06-17 11:49:09.000000000 +0200
> +@@ -1,4 +1,4 @@
> +-SUBDIRS = bin config doc sgml-iso-entities xml-iso-entities
> ++SUBDIRS = bin config sgml-iso-entities xml-iso-entities
> + 
> + sgmlcodir = $(prefix)/share/sgml
> + sgmlco_DATA = xml.dcl
> diff --git a/meta/recipes-devtools/sgml-common/sgml-common-native_0.6.3.bb b/meta/recipes-devtools/sgml-common/sgml-common-native_0.6.3.bb
> new file mode 100644
> index 0000000..7e9b923
> --- /dev/null
> +++ b/meta/recipes-devtools/sgml-common/sgml-common-native_0.6.3.bb
> @@ -0,0 +1,50 @@
> +SUMMARY = "Base utilities for working with SGML and XML"
> +DESCRIPTION = "The sgml-common package gathers very basic \
> +stuff necessary to work with SGML and XML, such as xml.dcl, \
> +a SGML declaration of XML; iso-entities, a list of the basic \
> +SGML ISO entities; and install-catalog, a script used to \
> +add entries to (or remove entries from) centralized catalogs \
> +whose entries are pointers to SGML open catalogs, \
> +as defined by OASIS."
> +HOMEPAGE = "http://sources.redhat.com/docbook-tools/"
> +LICENSE = "GPLv2"
> +# The COPYING file sgml-common ships with is just a symlink to
> +# /usr/share/automake/COPYING, which means we can't verify it
> +# using our normal means. :( Hash the README file instead as
> +# LIC_FILES_CHKSUM is still required.
> +LIC_FILES_CHKSUM = "file://README;md5=197bd940bf13548ac2198e4f77d3da92"

Can we add a patch which replaces the symlink with the actual file and
hash that. Seems slightly more robust... but only slightly.

> +SECTION = "base"
> +
> +PR = "r0"
> +
> +require sgml-common_${PV}.bb
> +inherit native
> +
> +S = "${WORKDIR}/sgml-common-${PV}"
> +
> +SYSROOT_PREPROCESS_FUNCS += "sgml_common_native_mangle"
> +
> +do_install_append() {
> +	# install-catalog script contains hard-coded references to
> +	# {sysconfdir}. Change it to ${D}${sysconfdir}.
> +	sed -i -e "s|${sysconfdir}/sgml|${D}${sysconfdir}/sgml|g" ${D}${bindir}/install-catalog
> +
> +	${D}${bindir}/install-catalog \
> +		--add ${D}${sysconfdir}/sgml/sgml-ent.cat \
> +		${D}${datadir}/sgml/sgml-iso-entities-8879.1986/catalog
> +
> +	${D}${bindir}/install-catalog \
> +		--add ${D}${sysconfdir}/sgml/sgml-docbook.cat \
> +		${D}${sysconfdir}/sgml/sgml-ent.cat
> +}
> +
> +sgml_common_native_mangle () {
> +	# Revert back to ${sysconfdir} path in install-catalog
> +	sed -i -e "s|${D}${sysconfdir}/sgml|${sysconfdir}/sgml|g" ${SYSROOT_DESTDIR}${STAGING_BINDIR}/install-catalog
> +	# Change path from ${D}${datadir}/sgml/sgml-iso-entities-8879.1986/catalog to ${datadir}/sgml/sgml-iso-entities-8879.1986/catalog in sgml-ent.cat
> +	sed -i -e "s|${D}${datadir}/sgml/sgml-iso-entities-8879.1986/catalog|${datadir}/sgml/sgml-iso-entities-8879.1986/catalog|g" ${SYSROOT_DESTDIR}${sysconfdir}/sgml/sgml-ent.cat
> +	# Change path from ${D}${sysconfdir}/sgml/sgml-ent.cat|${sysconfdir}/sgml/sgml-ent.cat to ${sysconfdir}/sgml/sgml-ent.cat in sgml-ent.cat
> +	sed -i -e "s|${D}${sysconfdir}/sgml/sgml-ent.cat|${sysconfdir}/sgml/sgml-ent.cat|g" ${SYSROOT_DESTDIR}${sysconfdir}/sgml/sgml-docbook.cat
> +	# Remove ${D} path from catalog file created by install-catalog script
> +	sed -i -e "s|${D}||g" ${SYSROOT_DESTDIR}${sysconfdir}/sgml/catalog
> +}
> diff --git a/meta/recipes-devtools/sgml-common/sgml-common_0.6.3.bb b/meta/recipes-devtools/sgml-common/sgml-common_0.6.3.bb
> new file mode 100644
> index 0000000..78afa39
> --- /dev/null
> +++ b/meta/recipes-devtools/sgml-common/sgml-common_0.6.3.bb
> @@ -0,0 +1,53 @@
> +SUMMARY = "Base utilities for working with SGML and XML"
> +DESCRIPTION = "The sgml-common package gathers very basic \
> +stuff necessary to work with SGML and XML, such as xml.dcl, \
> +a SGML declaration of XML; iso-entities, a list of the basic \
> +SGML ISO entities; and install-catalog, a script used to \
> +add entries to (or remove entries from) centralized catalogs \
> +whose entries are pointers to SGML open catalogs, \
> +as defined by OASIS."
> +HOMEPAGE = "http://sources.redhat.com/docbook-tools/"
> +LICENSE = "GPLv2"
> +# The COPYING file sgml-common ships with is just a symlink to
> +# /usr/share/automake/COPYING, which means we can't verify it
> +# using our normal means. :( Hash the README file instead as
> +# LIC_FILES_CHKSUM is still required.
> +LIC_FILES_CHKSUM = "file://README;md5=197bd940bf13548ac2198e4f77d3da92"

as above

> +SECTION = "base"
> +
> +PR = "r0"
> +
> +SRC_URI = "ftp://sources.redhat.com/pub/docbook-tools/new-trials/SOURCES/sgml-common-${PV}.tgz \
> +           file://autohell.patch"
> +
> +SRC_URI[md5sum] = "103c9828f24820df86e55e7862e28974"
> +SRC_URI[sha256sum] = "7dc418c1d361123ffc5e45d61f1b97257940a8eb35d0bfbbc493381cc5b1f959"
> +
> +inherit autotools
> +
> +do_compile_append() {
> +	# install-catalog script contains hardcoded references to /etc/sgml
> +	sed -i -e "s|/etc/sgml|${sysconfdir}/sgml|g" bin/install-catalog
> +}
> +
> +FILES_sgml-common_append = " ${datadir}/sgml"
> +
> +pkg_postinst() {
> +	install-catalog \
> +		--add ${sysconfdir}/sgml/sgml-ent.cat \
> +		${datadir}/sgml/sgml-iso-entities-8879.1986/catalog
> +
> +	install-catalog \
> +		--add ${sysconfdir}/sgml/sgml-docbook.cat \
> +		${sysconfdir}/sgml/sgml-ent.cat
> +}
> +
> +pkg_postrm() {
> +	install-catalog \
> +		--remove ${sysconfdir}/sgml/sgml-ent.cat \
> +		${datadir}/sgml/sgml-iso-entities-8879.1986/catalog
> +
> +	install-catalog \
> +		--remove ${sysconfdir}/sgml/sgml-docbook.cat \
> +		${sysconfdir}/sgml/sgml-ent.cat
> +}

-- 
Joshua Lock
        Intel Open Source Technology Centre



  reply	other threads:[~2011-01-28 15:27 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-27 22:42 [PATCH 0/9] docbook-utils and related recipes Scott Garman
2011-01-27 22:42 ` [PATCH 2/9] docbook-sgml-dtd: new recipes - v3.1, v4.1, v4.5 Scott Garman
2011-01-28 15:27   ` Joshua Lock
2011-01-27 22:42 ` [PATCH 1/9] sgml-common: new recipe v0.6.3 Scott Garman
2011-01-28 15:26   ` Joshua Lock [this message]
2011-01-29  0:06     ` Scott Garman
2011-01-29  0:19       ` Joshua Lock
2011-01-27 22:42 ` [PATCH 5/9] opensp: new recipe v1.5 Scott Garman
2011-01-28 15:27   ` Joshua Lock
2011-01-27 22:42 ` [PATCH 7/9] docbook-utils: new recipe v0.6.14 Scott Garman
2011-01-27 22:42 ` [PATCH 6/9] openjade: new recipe v1.3.2 Scott Garman
2011-01-27 22:42 ` [PATCH 3/9] docbook-dsssl-stylesheets: new recipe v1.79 Scott Garman
2011-01-28 15:27   ` Joshua Lock
2011-01-28 21:48     ` Scott Garman
2011-01-29  0:18       ` Joshua Lock
2011-01-27 22:42 ` [PATCH 8/9] iputils: enable generation of man pages Scott Garman
2011-01-27 22:42 ` [PATCH 4/9] sgmlspl: new recipe, v1.03ii Scott Garman
2011-01-27 22:42 ` [PATCH 9/9] distro_tracking_fields.inc: added docbook-utils and dependencies Scott Garman
2011-01-28 15:27 ` [PATCH 0/9] docbook-utils and related recipes Joshua Lock
2011-01-29  1:45   ` Scott Garman
2011-01-28 18:42 ` Saul Wold
  -- strict thread matches above, loose matches on Subject: below --
2011-01-29  1:46 [PATCH 0/9] docbook-utils and related recipes, v2 Scott Garman
2011-01-29  1:46 ` [PATCH 1/9] sgml-common: new recipe v0.6.3 Scott Garman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1296228416.2704.17.camel@scimitar \
    --to=josh@openedhand.com \
    --cc=poky@yoctoproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox