Attached please find mwavem-1.0.2.ebuild. The mwavem is a user level application that works with the mwave kernel driver to provide support for the ACP (Mwave) WinModem in IBM ThinkPad 600, 600E and 770[X|Z] laptops. This is my first shot at a new ebuild. As far as I can tell, it has no dependencies.
Created attachment 450 [details] mwavem-1.0.2.ebuild (New package)
Forgot to add: I've put in app-misc on my system. Perhaps sys-apps might be the place for it?
Please take a look at /usr/portage/skel.ebuild. Your ebuild should look very much like that (minus comments). Even if you have no DEPEND or RDEPEND, you need to set them in the ebuild.
Created attachment 2299 [details] Shell script to register and deregister MWave Modem device nodes This script is needed by the entries in /etc/devfsd.conf to register and deregister the device nodes for the MWave Modem driver. It simply creates or destroys the symlink /dev/misc/mwave -> /dev/modems/mwave
Created attachment 2300 [details] Updated proposed mwavem-1.0.2.ebuild (New package) Updated ebuild for MWaveM 1.0.2, patterned after /usr/portage/skel.ebuild.
The required entries in /dev/devfsd.conf are: REGISTER ^misc/mwave$ EXECUTE /usr/sbin/mwave-handler register UNREGISTER ^misc/mwave$ EXECUTE /usr/sbin/mwave-handler unregister
Created attachment 2335 [details] Final (hopefully) proposed mwavem-1.0.2.ebuild (New Package) This is what I believe to be the final version of the mwavem-1.0.2.ebuild file. On configuration it disables mwavedd, the device driver. This is now part of the kernel, and should be built there. The compilation is patched to correctly add the module alias to /etc/modules.d/aliases instead of /etc/modules.conf. The src_install() copies mwave-dev-handler to /usr/sbin and updates /etc/devfsd.conf I currently keep this in app-misc, but sys-apps might also be a good location.
Created attachment 2336 [details] ChangeLog for mwavem-1.0.2.ebuild Initial ChangeLog for mwavem-1.0.2.ebuild
Created attachment 2337 [details] Digest for mwavem-1.0.2.ebuild
I believe this ebuild is now complete. The ebuild itself has been updated to match the specs in /usr/portage/skel.ebuild, and passes (to my satisfaction at least) lintool screening. The Makefiles of the package have been patched to correct a sandbox error and apply the module aliases to Gentoo's /etc/modules.d/aliases. The ebuild adds the correct entries to /etc/devfsd.conf and installs the /usr/sbin/mwave-dev-handler script. Attachment # 2335 [details] is the final ebuild. Attachment # 2336 [details] is the initial ChangeLog Attachment # 2337 [details] is the Digest file Attachment # 2299 [details] is an addition file to be stored in mwavem/files, for installation to /usr/sbin
One more request, since you did such a good job preparing this. Please tar up your /usr/portage/app-misc/mwave directory and post that. The unfortunate thing about bugzilla attachments is that they lose their filenames (unless you explicitly type it). Thanks! I'll get this into portage soon.
Created attachment 2338 [details] Final mwavem-1.0.2.ebuild Obsoletes attachment # 2335 [details], which had a spelling error in a filename. This is what I believe to be the final version of the mwavem-1.0.2.ebuild file. On configuration it disables mwavedd, the device driver. This is now part of the kernel, and should be built there. The compilation is patched to correctly add the module alias to /etc/modules.d/aliases instead of /etc/modules.conf. The src_install() copies mwave-dev-handler to /usr/sbin and updates /etc/devfsd.conf I currently keep this in app-misc, but sys-apps might also be a good location.
Created attachment 2339 [details] tarball of /usr/portage/app-misc/mwavem.tar Complete tarball of /usr/portage/app-misc/mwavem, NOT gzipped. Includes the fixed ebuild with correct filename. If you have any other hints/suggestions for improving this ebuild, I'd love to hear them. This is only the second one I've done, and it's a little more complex than I thought at first glance. The only thing bothering me about it yet is that it will add multiple entries to /etc/devfsd.conf if you merge it repeatedly. Thanks, Matthew
Well, as far as the update of devfsd.conf, it is probably better to leave it alone and just put einfo's in the ebuild telling the user what to do. I can't remember hearing a discussion about that exactly, though. To do it your way, you might want to put a comment before your added lines. Then you can grep for that when you go to install, i.e. # mwavem-1.0.2 .... I think if you are going to insert text into the devfsd.conf you need to remove it when the package is unmerged. Furthermore, consider that not everyone using Gentoo uses devfsd.
Created attachment 2343 [details] Revised mwavem.tar of app-misc/mwavem Revised tarball of /usr/portage/app-misc/mwavem Removed devfs specific install actions, added einfo lines to pkg_postinst().
Great Job! Committed (finally)