Hi,
I plan to package pLoader for Debian and its derivatives. I have two major problems at this moment:
1) There's no such script/Makefile which install the files to their correct places,
2) Even if there would be one, src/ploader.pl require additional perl files to be relative its location. If it would go to /usr/bin/ as ploader (extension a must go), the additional files should reside at /usr/bin/../res/ -> /usr/res/ which is not an FHS allowed location.
Last but not least the copyright states only 2008 for its validity. It should be 2008- IMHO.
Last edited by Marki (2010-01-27 19:21:26)
Offline
Marki wrote:
I plan to package pLoader for Debian and its derivatives. I have two major problems at this moment:
1) There's no such script/Makefile which install the files to their correct places,
It's the same for piwigo. No debian files in source tree. You must to add them by hand ! :-)
Marki wrote:
2) Even if there would be one, src/ploader.pl require additional perl files to be relative its location. If it would go to /usr/bin/ as ploader (extension a must go), the additional files should reside at /usr/bin/../res/ -> /usr/res/ which is not an FHS allowed location.
I think the only file that will go in /usr/bin is ploader.pl and it must be rename ploader without extension !
res directory is for resources. I'm not very experienced in debian packages but even if the debian package must keep source tree in his original format we can reorganise package to be FHS compliant. We can change code a little. If it make sense we can backport modifications in pLoader source tree.
Marki wrote:
Last but not least the copyright states only 2008 for its validity. It should be 2008- IMHO.
Ok for me.
It must be 2008-2010
p.s: are you Kinga ?
Offline
nicolas wrote:
It's the same for piwigo. No debian files in source tree. You must to add them by hand ! :-)
I don't speak about debian/ files here but Makefile / install.sh or friends. Should I install everything myself, file by file?
nicolas wrote:
I think the only file that will go in /usr/bin is ploader.pl and it must be rename ploader without extension !
This is what I wrote if you read it again.
nicolas wrote:
res directory is for resources. I'm not very experienced in debian packages but even if the debian package must keep source tree in his original format we can reorganise package to be FHS compliant. We can change code a little. If it make sense we can backport modifications in pLoader source tree.
Packages can change sources, still diversions may make maintainership harder on the long run. The problem is pLoader meant to be user only and not as a system wide utility. On the other hand packages go system wide by their nature.
What's the copyright of pictures?
Yes, I'm the one who wrote you recently.
Offline
Is it possible to package pLoader under a /opt/pLoader directory?( my question may be stupid, I'm totally new to linux packaging issues )
Anyway, if you need changes in ploader.pl, let me know, I'll do my best to help you.
Offline
ron wrote:
Is it possible to package pLoader under a /opt/pLoader directory?( my question may be stupid, I'm totally new to linux packaging issues )
It is possible and would be fine there even if not FHS compilant. Please note that usually contrib programs (closed source ones) go there. Last but not least it wouldn't be in the PATH of users (yes, a symlink from /usr/bin/ would make it).
ron wrote:
Anyway, if you need changes in ploader.pl, let me know, I'll do my best to help you.
It was ages ago when I last touched Perl. Would it be possible to rework 'require's just like 'use' causes? I mean Perl would try /usr/share/perl5/Piwigo/ to load the additional Wx generated files and if they are not found it would try ../res/ ? I know that the former is for Perl modules, but don't know any better location ATM.
Also wxApp.pm::_readParams would try user's home first to load pLoader.ini and not the current directory.
Offline
Marki wrote:
Last but not least it wouldn't be in the PATH of users
It may be better on other platforms, such as MacOs, where pLoader currently cannot use the default perl.
Marki wrote:
Also wxApp.pm::_readParams would try user's home first to load pLoader.ini and not the current directory.
I agree if pLoader.ini contains user specific data. In fact it is not the case : it is just default values to fill the login dialog at the first connexion.
After, the actual user login parameters are stored in $HOME/.pLoader/pLoader.conf.
Last edited by ron (2010-01-28 22:37:19)
Offline
I started packaging pLoader yesterday and I found some problems already discover by Marki.
1) ploader.pl doesn't have a header for a perl script : #!/usr/bin/perl . Can we add without breaking something on windows or mac-os ?
2) ploader search for resources and locales relatively to the directory where it is installed. On debian (and probably on all linux distribution), binary must go in /usr/bin. It's ok for ploader but resources and locales cannot go in /usr/res not /usr/locales.
I think the right place for resources and locales can be /usr/share/ploader/res and /usr/share/locale/LANGAGE_CODE/LC_MESSAGES/ploader.mo. So it will not work with actual code. If anyone have an idea or better a solution to solve that, it will be great.
I can of course open tickets in the bugtracker.
I repeat my proposition. If someone is interessted in packaging pLoader with me, he can send me his ssh public key so that I can give him a write access to my git repository.
Offline
nicolas wrote:
1) ploader.pl doesn't have a header for a perl script : #!/usr/bin/perl . Can we add without breaking something on windows or mac-os ?
This is the easiest to solve, you can add a Debian related patch which add that line.
nicolas wrote:
2) ploader search for resources and locales relatively to the directory where it is installed. On debian (and probably on all linux distribution), binary must go in /usr/bin. It's ok for ploader but resources and locales cannot go in /usr/res not /usr/locales.
This needs to be done by upstream, until it's not fixed it can't be packaged.
nicolas wrote:
I repeat my proposition. If someone is interessted in packaging pLoader with me, he can send me his ssh public key so that I can give him a write access to my git repository.
pLoader itself also a small package and it doesn't really worth two people. Especially not two if one of them is upstream of Piwigo/pLoader. Piwigo itself may need two people, but not pLoader.
Offline
ron wrote:
Marki wrote:
Also wxApp.pm::_readParams would try user's home first to load pLoader.ini and not the current directory.
I agree if pLoader.ini contains user specific data. In fact it is not the case : it is just default values to fill the login dialog at the first connexion.
After, the actual user login parameters are stored in $HOME/.pLoader/pLoader.conf.
Still, pLoader as a package will install to system folders. Users won't know where to change their current directory to get those defaults. pLoader itself should look at default configuration locations such as /etc/pLoader.ini or such.
I think the correct way to look for configuration would be:
1) ~/.pLoader/pLoader.ini , if not exists:
2) /etc/pLoader.ini , if still not exists:
3) look for current directory , and last:
4) use hardcoded defaults from pLoader itself, and show a configuration dialog on first run.
Offline
Marki wrote:
nicolas wrote:
1) ploader.pl doesn't have a header for a perl script : #!/usr/bin/perl . Can we add without breaking something on windows or mac-os ?
This is the easiest to solve, you can add a Debian related patch which add that line.
I know I can use quilt or dpatch but I ask if it can be done upstream to avoid patch it. It's not a problem to package.
Marki wrote:
nicolas wrote:
2) ploader search for resources and locales relatively to the directory where it is installed. On debian (and probably on all linux distribution), binary must go in /usr/bin. It's ok for ploader but resources and locales cannot go in /usr/res not /usr/locales.
This needs to be done by upstream, until it's not fixed it can't be packaged.
It can also be done by quilt ! But like the other it will be easier to package
Marki wrote:
nicolas wrote:
I repeat my proposition. If someone is interessted in packaging pLoader with me, he can send me his ssh public key so that I can give him a write access to my git repository.
pLoader itself also a small package and it doesn't really worth two people. Especially not two if one of them is upstream of Piwigo/pLoader. Piwigo itself may need two people, but not pLoader.
As you want. But I really appreciate your advices. Thanks.
Offline
My packaging is almost ready. You can test it by modify your sources list.
Add that line in /etc/apt/sources.list
deb http://debian.nikrou.net/debian/ sid main contrib non-free
Then update your packages list :
apt-get update
The first time you will have a warning :
W: GPG error: http://debian.nikrou.net sid Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY CE5E2710C9BB2B3A
You must add the public key of my repository in your known keys.
wget http://debian.nikrou.net/debian/debian-nikrou-keyring.asc -O- | apt-key add -
And you can now install ploader :
apt-get install ploader
You must notice that that package is not an official package and I have to work on it to finish it. But I think it can be installed.
If you have questions, problems, tell me and I will try to help you.
Last edited by nicolas (2010-02-17 22:23:15)
Offline
Terrific.
It works like a charm :-)
Offline
nicolas wrote:
My packaging is almost ready. You can test it by modify your sources list.
You won't like me. This is all wrong.
First your package doesn't build by its dsc . It's not and should not be a Debian native package, so you miss the upstream tarball as .orig.tar.gz .
You don't have an ITP for pLoader and so your changelog is not filled in.
You should improve the long description, copyright states it's Piwigo and not pLoader.
You should delete the following files as they are empty: docs , postrm , preinst, prerm . Also README.Debian and README.source are also empty or please fill in if you want to keep it.
Next about an empty dir. You create /etc for some reason without any file or purpose (pLoader won't check for an ini file there as I see). Please install a default ini file there if you would like to keep it and make sure pLoader looks there for configuration.
Image for menu entries should be 32x32 pixels, yours is 210x100 pixels. I can't remember Applications/Network section in menus. It may go to Accessories or Graphics.
Last but not least what pushed me to the floor is your postinst . You rename the pLoader in it, which doesn't break the system, but very bad thing to do. I mean the system will know that you install /usr/bin/ploader.pl and won't find it. After your build, see debian/ploader/DEBIAN/md5sums . It shows what the system thinks about your package and won't realise where ploader.pl went after configuration.
An other thing that makes me wonder why do you present pLoader as 1.0.0 ? It is version 2.0.7c according to the website.
Really last is a 'minor' problem compared to the previous ones: your desktop file installed as /usr/share/applications/ploader.desktop/desktop and not as /usr/share/applications/ploader.desktop .
In summary I emphasis that your package is way wrong. Please don't take this as a personal offense but fix some of these problems at least before posting it to public review.
Last edited by Marki (2010-02-18 01:08:29)
Offline
I don't like the way you said things but I totally agree.
But you can notice that I said "You must notice that that package is not an official package and I have to work on it to finish it. But I think it can be installed."
All points are minor points for me even if they are really important ones to be able to import that package in debian officially.
Offline
Hello nicolas,
I tried to install the ploader package, but the repository doesn't contain this one. I can try to help you during my free time, if you want, to build the ploader package. You can find my mail adress in the french forum.