View previous topic :: View next topic |
Author |
Message |
Config Retired Dev
Joined: 25 May 2003 Posts: 187 Location: Zurich, Switzerland
|
Posted: Wed Jul 09, 2003 9:15 pm Post subject: Module Programming |
|
|
I just wrote a little proftpd module - but I don't know how to emerge proftp including this module. I would first have to patch the proftpd source and then add another ./configure, directive. How can I do that? _________________ Config - caught by a chronic disease called tuxmania.... |
|
Back to top |
|
|
Pythonhead Developer
Joined: 16 Dec 2002 Posts: 1801 Location: Redondo Beach, Republic of Calif.
|
Posted: Wed Jul 09, 2003 10:00 pm Post subject: |
|
|
Take a look at proftpd-1.2.9_rc1.ebuild, you should be able to tell from that.
Put the new ebuild in /usr/local/portage/net-ftp/proftpd and your patch in /usr/local/portage/net-ftp/proftpd/files
In src_unpack() you can patch it after unpack ${MY_P}.tar.bz2
Add your module to IUSE and check the myconf section, you can add the configure directive there. There are some examples for postgresql and mysql you can copy. |
|
Back to top |
|
|
Config Retired Dev
Joined: 25 May 2003 Posts: 187 Location: Zurich, Switzerland
|
Posted: Wed Jul 09, 2003 10:18 pm Post subject: |
|
|
Hmmm... I sort of don't like this method, although it works. I want to debug/develop this module, not just compile and use it.
I had the idea to download the source, compile it but witout doing a make install. But then, proftpd wouldn't start because it cannot figure out the ip of linux (my hostname). I cannot add it in /etc/hosts, since my ip is configured via dhcp....
But to make your approach work, I would just have to add a cp statement, this is clear - but where do I copy it to? The src_unpack doesn't say anthing about where it unpacks the source.
The configure part is straightforward, correct
Thanks _________________ Config - caught by a chronic disease called tuxmania.... |
|
Back to top |
|
|
Pythonhead Developer
Joined: 16 Dec 2002 Posts: 1801 Location: Redondo Beach, Republic of Calif.
|
Posted: Wed Jul 09, 2003 11:42 pm Post subject: |
|
|
Config wrote: | The src_unpack doesn't say anthing about where it unpacks the source.
|
If you do:
Code: | ebuild /usr/portage/net-ftp/proftpd-1.2.9_rc1.ebuild unpack |
You'll see what directory it is unpacked in.
A good way to learn what the ebuild variables are, such as ${A}, is to look at the 'environment' file. After you unpack the ebuild look at /var/tmp/portage/proftpd-1.2.9_rc1/temp/environment |
|
Back to top |
|
|
Genone Retired Dev
Joined: 14 Mar 2003 Posts: 9526 Location: beyond the rim
|
Posted: Thu Jul 10, 2003 3:40 pm Post subject: |
|
|
gives a lot of useful information for ebuilds. |
|
Back to top |
|
|
fusion Tux's lil' helper
Joined: 02 Nov 2002 Posts: 119
|
|
Back to top |
|
|
|