First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 87509
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Text-Markup Team <text-markup@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Octavio Ruiz (Ta^3) <tacvbo@tacvbo.net>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
sgmltools-lite.diff sgmltools-lite fix patch Torsten Veller 2005-04-02 10:08 0000 958 bytes Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 87509 depends on: Show dependency tree
Bug 87509 blocks: 87491
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2005-03-31 23:00 0000
Inside

/usr/share/sgml/misc/sgmltools/python
/usr/share/sgml/misc/sgmltools/python/backends

there are only '.py' files. In order to sgmltools work, should be '.pyc' files also.
They are auto-generated when sgmtools runs as root. Should the ebuild generate them inside ${WORKDIR} and then merge them to the tree?

The lack of those archives (.pyc) causes sandbox violations when an ebuild/makefile detects this tools and try to generate html doc from sgml (like mutt-ng ebuild).

------- Comment #1 From Torsten Veller 2005-04-02 10:08:08 0000 -------
Created an attachment (id=55114) [edit]
sgmltools-lite fix

generates byte compiled python modules

------- Comment #2 From Octavio Ruiz (Ta^3) 2005-04-02 10:54:17 0000 -------
Cool, it works. Can it be commited? :-)

------- Comment #3 From Torsten Veller 2005-04-02 13:44:45 0000 -------
My patch was *not* correct: It misses the sgml-catalog functions!

It is necessary to add sgml-catalog_pkg_post{inst,rm} to pkg_post{inst,rm}.

Sorry.

------- Comment #4 From Octavio Ruiz (Ta^3) 2005-04-02 21:35:16 0000 -------
Okey, I reach my top of knowledge in sgml tools related things.. (it was so
easy ;-P). I'm doing things without knowing a lot with what I'm doing..

First, I can not find any example...

$ find . -type f -name "*ebuild" -exec egrep -i sgml-catalog_pkg /dev/null {}
\;
tacvbo@avalancha portage $

Then, there is no man page for sgml-catalog.eclass...

so, I directly see sgml-catalog.eclass.. and I have a question based on my
observation. If you dont explicit put the sgml-catalog_pkg_post{inst,rm} to
pkg_post{inst,rm} any way its executed. Also (I think) this is wy there is no
package who uses that functions. (Or maybe I'm using them wrong).

I have the same behavior (and files) adding that functions or not. Exactly the
same.

--- /usr/portage/app-text/sgmltools-lite/sgmltools-lite-3.0.3-r7.ebuild
2005-03-15 08:35:23.000000000 -0600
+++ /usr/local/portage/app-text/sgmltools-lite/sgmltools-lite-3.0.3-r7.ebuild  
2005-04-02 22:59:44.000000000 -0600
@@ -2,7 +2,7 @@
 # Distributed under the terms of the GNU General Public License v2
 # $Header:
/var/cvsroot/gentoo-x86/app-text/sgmltools-lite/sgmltools-lite-3.0.3-r7.ebuild,v
1.14 2005/03/15 14:28:09 seemant Exp $

-inherit sgml-catalog
+inherit sgml-catalog python

 DESCRIPTION="Python interface to SGML software in a DocBook/OpenJade env"
 HOMEPAGE="http://sgmltools-lite.sourceforge.net/"
@@ -74,5 +74,17 @@

 }

+pkg_postinst() {
+       python_mod_optimize ${ROOT}usr/share/sgml/misc/sgmltools/python
+       sgml-catalog_pkg_postinst "/etc/sgml/sgml-lite.cat" \
+               "/usr/share/sgml/stylesheets/sgmltools/sgmltools.cat"
+}
+
+pkg_postrm() {
+       python_mod_cleanup ${ROOT}usr/share/sgml/misc/sgmltools/python
+       sgml-catalog_pkg_postrm "/etc/sgml/sgml-lite.cat" \
+               "/usr/share/sgml/stylesheets/sgmltools/sgmltools.cat"
+}
+
 sgml-catalog_cat_include "/etc/sgml/sgml-lite.cat" \
        "/usr/share/sgml/stylesheets/sgmltools/sgmltools.cat"

This patch is what you was talking about, or not?

My disclaimer is that I can really be wrong, so dont beleive a lot. :-P

------- Comment #5 From Octavio Ruiz (Ta^3) 2005-04-02 22:00:10 0000 -------
This is one of my "testings":

1i - dir for files modified by ebuild without patches (after installed)
1u - dir for files modified by ebuild without patches (after uninstalled)
2i - dir for files modified by ebuild with patches (after installed)
2u - dir for files modified by ebuild with patches (after uninstalled)

Inside that dirs (if they exist), /etc/sgml/sgml-lite.cat, /usr/share/sgml/stylesheets/sgmltools/sgmltools.cat and /etc/sgml/catalog files.

The example only shows diffs between only for /etc/sgml/catalog (for the example purpose), and in both cases are the same (it just changes the timestamps) , so maybe I'm not too wrong, or maybe its a sophism and I'm just deceiving myself and doing weird and incoherent things. :P

tacvbo@avalancha tmp1 $ diff -ur 1*
diff -ur 1i/catalog 1u/catalog
--- 1i/catalog  2005-04-02 23:46:56.000000000 -0600
+++ 1u/catalog  2005-04-02 23:47:23.000000000 -0600
@@ -7,4 +7,3 @@
 CATALOG "/etc/sgml/dsssl-docbook-stylesheets.cat"
 CATALOG "/etc/sgml/sgml-docbook-4.0.cat"
 CATALOG "/etc/sgml/xml-simple-docbook-4.1.2.4.cat"
-CATALOG "/etc/sgml/sgml-lite.cat"
tacvbo@avalancha tmp1 $ diff -ur 2*
diff -ur 2i/catalog 2u/catalog
--- 2i/catalog  2005-04-02 23:48:24.000000000 -0600
+++ 2u/catalog  2005-04-02 23:49:12.000000000 -0600
@@ -7,4 +7,3 @@
 CATALOG "/etc/sgml/dsssl-docbook-stylesheets.cat"
 CATALOG "/etc/sgml/sgml-docbook-4.0.cat"
 CATALOG "/etc/sgml/xml-simple-docbook-4.1.2.4.cat"
-CATALOG "/etc/sgml/sgml-lite.cat"
tacvbo@avalancha tmp1 $ diff -u <(diff -ur 1*) <(diff -ur 2*)
--- /dev/fd/63  2005-04-02 23:49:36.818400984 -0600
+++ /dev/fd/62  2005-04-02 23:49:36.820400680 -0600
@@ -1,6 +1,6 @@
-diff -ur 1i/catalog 1u/catalog
---- 1i/catalog 2005-04-02 23:46:56.000000000 -0600
-+++ 1u/catalog 2005-04-02 23:47:23.000000000 -0600
+diff -ur 2i/catalog 2u/catalog
+--- 2i/catalog 2005-04-02 23:48:24.000000000 -0600
++++ 2u/catalog 2005-04-02 23:49:12.000000000 -0600
 @@ -7,4 +7,3 @@
  CATALOG "/etc/sgml/dsssl-docbook-stylesheets.cat"
  CATALOG "/etc/sgml/sgml-docbook-4.0.cat"


------- Comment #6 From Torsten Veller 2005-04-03 12:57:36 0000 -------
see http://www.gentoo.org/proj/en/devrel/handbook/handbook.xml?part=2&chap=2

sgml-catalog's EXPORT_FUNCTIONS define default functions for pkg_postrm and pkg_postinst. These were replaced by the functions in my patch. To reactivate them it's necessary to call them explicitly:

For example:
pkg_postinst() {
   python_mod_optimize ${ROOT}usr/share/sgml/misc/sgmltools/python
   sgml-catalog_pkg_postinst
}

------- Comment #7 From Leonardo Boshell (RETIRED) 2005-05-29 07:23:50 0000 -------
Resolved in sgmltools-lite-3.0.3-r8.ebuild. Thanks tove :).

First Last Prev Next    No search results available      Search page      Enter new bug