Hi, I am currently trying to package gnome-activity-journal for Fedora, and in doing so I have run into a few issues with the distutils installation setup.
Now I have to admit that I am not an expert at distutils, but I have attached a patch that tries to make the installation a bit smoother - at least seen from a packagers perspective. One thing I tried to fix was to make sure that all needed files were actually getting installed. This meant making sure that the desktop file and the mo files were getting installed. Apparently there is no sensible way to install GConf schemas to the right location using distutils, so I haven't solved that issue, unfortunately. When creating a package it is generally frowned upon to have absolute symlinks included. Therefore I have removed all the symlinks. The symlinking of share/icons didn't seem to be needed anymore, so that one just got removed. Symlinking the icon for gnome-activity-journal has been replaced by an extra copy of the icon (hopefully not a problem). The symlink for the main executable has been replaced with a small shell script that merely execs the actual executable. The script will have to be modified during installation to point to the correct installation path of gnome-activity-journal but I haven't done that yet - I first wanted to find out if this would be an acceptable way forward. I hope that some of this work can be used by you. Regards. -- Mads Villadsen <[email protected]>
=== modified file 'extra/gnome-activity-journal.desktop.in' --- extra/gnome-activity-journal.desktop.in 2010-01-17 19:28:29 +0000 +++ extra/gnome-activity-journal.desktop.in 2010-02-26 12:08:43 +0000 @@ -3,6 +3,6 @@ _Name=Activity Journal _GenericName=Activity Journal _Comment=Browse a chronological log of your activities and easily find files, contacts, etc. -Exec=gnome-activity-journal +Exec=gnome-activity-journal.sh Icon=gnome-activity-journal Categories=GTK;Utility; === added file 'gnome-activity-journal.sh' --- gnome-activity-journal.sh 1970-01-01 00:00:00 +0000 +++ gnome-activity-journal.sh 2010-02-26 12:08:21 +0000 @@ -0,0 +1,6 @@ +#!/bin/bash + +PREFIX=/usr +GAJDIR=share/gnome-activity-journal + +exec $PREFIX/$GAJDIR/gnome-activity-journal \ No newline at end of file === modified file 'setup.cfg' --- setup.cfg 2010-01-19 17:59:18 +0000 +++ setup.cfg 2010-02-26 12:09:09 +0000 @@ -2,4 +2,4 @@ domain=gnome-activity-journal [email protected] desktop_files=[('share/applications', ('extra/gnome-activity-journal.desktop.in',))] -schemas_files=[('share/gconf/schemas', ('extra/gnome-activity-journal.schemas.in',))] +schemas_files=[('etc/gconf/schemas', ('extra/gnome-activity-journal.schemas.in',))] === modified file 'setup.py' --- setup.py 2010-02-23 13:57:42 +0000 +++ setup.py 2010-02-26 12:16:12 +0000 @@ -46,22 +46,6 @@ else: self._destdir = self.prefix orig_install.run(self) - # Ensure the needed directories exist - self._create_directory('bin') - self._create_directory('share/pixmaps') - # Create a symlink for the executable file - self._create_symlink( - 'share/gnome-activity-journal/gnome-activity-journal', - 'bin/gnome-activity-journal') - # Symlink the 48x48 PNG icon into share/pixmaps - self._create_symlink( - 'share/gnome-activity-journal/data/icons/hicolor/48x48/apps/' \ - 'gnome-activity-journal.png', - 'share/pixmaps/gnome-activity-journal.png') - # Symlink the icons so that the Journal can find them - self._create_symlink( - 'share/icons/', - 'share/gnome-activity-journal/data/icons') class _build_i18n(build_i18n.build_i18n): @@ -117,9 +101,18 @@ platforms = ['GNU/Linux'], data_files = list_from_lists( [('share/gnome-activity-journal', ['gnome-activity-journal'])], + [('bin/', ['gnome-activity-journal.sh'])], [('share/gnome-activity-journal/data', glob('data/*.svg'))], [('share/gnome-activity-journal/data/zlogo', glob('data/zlogo/*.png'))], [('share/pixmaps/', ['data/gnome-activity-journal.xpm'])], + [('share/pixmaps/', ['data/icons/hicolor/48x48/apps/gnome-activity-journal.png'])], + + [('share/applications/', ['build/share/applications/gnome-activity-journal.desktop'])], + recursive_install('share/locale', 'build/mo/', '', + ext=['.mo']), + # gconf schemas can apparently not be easily installed using distutils + #[('etc/gconf/schemas/', ['build/etc/gconf/schemas/gnome-activity-journal.schemas'])], + recursive_install('share/icons/hicolor', 'data/icons/hicolor/', '', ext=['.png', '.svg']), recursive_install('share/gnome-activity-journal', 'src/', ext=['.py']),
_______________________________________________ Mailing list: https://launchpad.net/~gnome-zeitgeist-users Post to : [email protected] Unsubscribe : https://launchpad.net/~gnome-zeitgeist-users More help : https://help.launchpad.net/ListHelp

