Summary: | Version Bump app-misc/iguanaIR-1.0.1 | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Derek Adams <juugcatm> |
Component: | Current packages | Assignee: | Joerg Bornkessel (RETIRED) <hd_brummy> |
Status: | RESOLVED FIXED | ||
Severity: | enhancement | CC: | kabili207, media-tv |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
Ebuild file
The /etc/init.d/ script for the files directory iguanaIR-1.0_pre2.ebuild iguanaIR-1.0-gentoo.diff iguanaIR-1.0-gentoo.diff iguanaIR-1.0.1.ebuild iguanaIR-1.0-gentoo.diff |
Description
Derek Adams
2010-03-11 01:32:02 UTC
Created attachment 223103 [details]
Ebuild file
This is the ebuild for the package.
Created attachment 223105 [details]
The /etc/init.d/ script for the files directory
The /etc/init.d/ script for the files directory
This is sorely needed. The iguanaIR I ordered last week doesn't work without the newer driver:
Sep 08 19:47:49 2010 ERROR: Unsupported hardware version 774
But the ebuild posted here does not work:
>>> Original instance of package unmerged safely.
* Adding group 'iguanair' to your system ...
* - Groupid: next available
* Adding user 'iguanair' to your system ...
* - Userid: 106
* Do not specify /sbin/nologin yourself, use -1
* ERROR: app-misc/iguanaIR-1.0_pre2 failed:
* Pass '-1' as the shell parameter
*
* Call stack:
* ebuild.sh, line 54: Called pkg_postinst
* environment, line 5587: Called enewuser 'iguanair' '-1' '/sbin/nologin' '-1' 'iguanair,usb'
* environment, line 4199: Called die
* The specific snippet of code:
* die "Pass '-1' as the shell parameter";
*
* If you need support, post the output of 'emerge --info =app-misc/iguanaIR-1.0_pre2',
* the complete build log and the output of 'emerge -pqv =app-misc/iguanaIR-1.0_pre2'.
* This ebuild is from an overlay: '/usr/local/portage/'
* The complete build log is located at '/var/tmp/portage/app-misc/iguanaIR-1.0_pre2/temp/build.log'.
* The ebuild environment file is located at '/var/tmp/portage/app-misc/iguanaIR-1.0_pre2/temp/environment'.
* S: '/var/tmp/portage/app-misc/iguanaIR-1.0_pre2/work/iguanaIR-1.0_pre2'
!!! FAILED postinst: 1
Changing it to -1 fixes the problem. But there are still a lot of issues with this ebuild. You didn't installed the udev rules. So the directory for the device doesn't get created. It simply doesn't work.
In general, I'm not sure it's such a good idea to keep trying to duplicate all the work upstream. There's already an init script provided. In fact, they specifically have a gentoo mode in there. Most importantly, it supports a "rescan" command, which the udev rule calls to create the device in /dev. Your init script doesn't do that. Again, no device. Client doesn't work.
Also, you're manually doing a make on each executable one by one instead of calling the default make target like in the original ebuild. And again you're installing the files manually one by one instead of using the make install like the last version.
The problem with your approach is that every time there's a version bump, you've got to recheck all the make targets and update each and every one manually. You'll also have to keep your init script up to date. A simple ebuild version rename will almost never work.
Sure, you get a neater init script tailor made for gentoo and you don't have to create the user before the install and the whole thing fits into the whole sandbox concept much better. But remember this isn't exactly a popular package like firefox or the linux kernel. By making it so labor intensive, you're guaranteeing that future updates will be even slower than it already is.
And since you're making a new ebuild from scratch, you're also throwing away all the work in the previous ebuild, including some gentoo customizations which your ebuild does not have. I hope there're no hard feelings. But every thing that you changed from the original ebuild seems like a fundamentally bad idea to me. Things are done that way in the original ebuild for good reasons. It's much better to simply build on the original ebuild and try to get it work.
Created attachment 246928 [details]
iguanaIR-1.0_pre2.ebuild
Updated ebuild based on the existing one in portage. Changes:
1. Add user before install so "make install" just works. Also removed the useradd in the Makefile because it won't work in the sandbox.
2. Moved /etc/iguanaIR/iguanaIR to /etc/conf.d/iguanaIR. It's not a config file. It's a file sourced by the init script. All other init scripts in gentoo put their sourced files under /etc/conf.d.
3. Set distro to "gentoo" manually in the init option file. They actually attempt to autodetect the distro by reading /etc/issue. Unfortunately, we don't have the words "gentoo" in there. So that never works. Fortunately they do provide the option to set it manually.
4. asneeded patch removed. Unfortunately I don't know enough about asneeded to understand what it's doing. So I can't update that patch. But I tried compiling with asneeded in my LDFLAGS and it just works. Not sure if it's just because the rest of my system doesn't have asneeded. But I don't have the time to rebuild the whole system to test it. Sorry. Someone else can update it as needed.
Created attachment 246930 [details, diff]
iguanaIR-1.0-gentoo.diff
Updated gentoo.diff. Put this under files/
Created attachment 246983 [details, diff]
iguanaIR-1.0-gentoo.diff
Fixed missing a mode 644 change in original portage gentoo.diff. iguanaIR.h no longer executable. :-)
Created attachment 258664 [details]
iguanaIR-1.0.1.ebuild
1.0.1 has been released. 1.0_pre2 is no longer available.
What's changed:
- Added lsb-release dependency to get their distro detection work automatically.
- Added RESTRICT mirror for those who're downloading this from bugzilla for use directly. (Sounds like this could take some time to get to the portage tree.)
Created attachment 258666 [details, diff]
iguanaIR-1.0-gentoo.diff
New diff for the 1.0.1 source.
What's changed:
- Changes for asneeded
- Removed adduser from makefile entirely instead of running "true"
- They now started using the pidofproc function from LSB, which Gentoo doesn't have. Added a hack to use pidof to fake one. (The two are actually different. But because of the way they're currently using this function, it shouldn't be noticeable.)
- Didn't include any unnecessary changes this time. For e.g., I left the iguanaIR.h executable. Also let it install the empty directory. I see that this is still not in portage. Sounds like we don't have much manpower to keep up with upstream releases with this little-used package. Better live with a little cosmetic problem than the diff didn't patch. You can add them back if you have time.
Some of these changes, especially the asneeded ones, looks like they really should be submitted upstream. That'll make future updates so much easier. FYI, upstream is very open to changes if you'd just let them know what the problem is.
1.0.1 in Portage. It may not be perfect, but 0.93 had also several bugs. Please give it a try and file *new bugs* if you have issues. |