|
From: Andrea R. <ari...@pi...> - 2004-11-16 14:16:03
|
Hi,
I was working to a new Fink package for the new PyX 0.7, when realized
that the *.lfs files are not found by PyX because are searched in the
wrong place. After digging a little bit I've found a solution that I
think is far less than optimal. It consists of a little patch to
setup.py:
--- PyX-0.7/setup.py.orig Mon Nov 15 16:30:04 2004
+++ PyX-0.7/setup.py Tue Nov 16 13:24:08 2004
@@ -41,7 +41,7 @@
#
data_files = [# share/pyx is taken relative to "setup.py install
--home=..."
- ("share/pyx", ["pyx/lfs/10pt.lfs",
+ ("share/pyx-py@PYTHON_FLAVOR@", ["pyx/lfs/10pt.lfs",
"pyx/lfs/11pt.lfs",
"pyx/lfs/12pt.lfs",
"pyx/lfs/10ptex.lfs",
@@ -53,7 +53,7 @@
"pyx/lfs/foils30pt.lfs",
"contrib/pyx.def"]),
# /etc is taken relative to "setup.py install --root=..."
- ("/etc", ["pyxrc"])]
+ ("@PREFIX@/etc", ["pyxrc"])]
#
# pyx_build_py
@@ -95,8 +98,11 @@
def run(self):
install_data.run(self)
- self.pyx_lfsdir = self.pyx_sharedir =
os.path.join(self.install_dir, "share", "pyx")
- self.pyx_pyxrc = os.path.join(self.root or "/", "etc", "pyxrc")
+ self.pyx_lfsdir = self.pyx_sharedir = os.path.join("@PREFIX@",
"share", "pyx-py@PYTHON_FLAVOR@")
+ self.pyx_pyxrc = os.path.join("@PREFIX@", "etc", "pyxrc")
where @PREFIX@ is replaced before install phase by the Fink prefix
directory (usually /sw).
As far as I can remember Andre uses Fink as well, so I'm wondering if
he know a better way of getting PyX installed with the right paths
written in siteconfig.py
I've also read an old thread on PyX-devel (that I missed back on
April), among Andre, Joerg and Fernando Perez about this topic, but it
wasn't of much help, perhaps I've missed the point...
Thanks in advance,
Andrea.
|