tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Improvements to the bootstrap script

Hi tach-pkg list

On the behalf of The Illumos Pkgsrc Project (ipp for now), I would like to start a discussion about how we could improve the pkgsrc bootstrap script. First a little history about ipp. I started this project, because I wanted a ports like system on SunOS, but instead of inventing my own, I knew pkgsrc could do the job.
But making a vanilla bootstrap on SunOS, quickly runs into a lot of problems, wrong PATH when you bootstrap, missing host dependencies, packages that needs patches etc. etc. The way we currently work around some of these problems at ipp, is to provide our own script But there are agreements in the community, that pkgsrc does not need to be more fragmented into local workarounds. Therefore I would like to list some ideas and improvements to the bootstrap script for discussion:

1) A function to get and update pkgsrc via cvs. This means, instead of first getting the pkgsrc tree and then bootstrap, you could get the bootstrap script and do something like bootstrap -s (sync) to get the tree. We could also have flags for switching branch and mirrors. ipp has these functions already.

2) A function to install host dependencies for supported OS' (in our case Illumos/Openindiana) e.g. bootstrap -d. I know that this means that bootstrap should know about a lot of different package managers, and list of witch host dependencies, different OS's needs. You shouldn't be forced to use this function, but meant to be a service for supported OS's. ipp has this function, but only for Openindiana.

3) A function to bootstrap multiply localbases. This is more or less a simple --prefix, but instead of choosing a path, you could just give the localbase a name and it would bootstrap into a standard location. In the ipp script we have this function, and bootstrap into e.g. /opt/ipp/pkg, /opt/ipp/test etc. This function would make it very easy to test different compilers, or have both a 32 and 64 bit environment. We could also integrate functions to list and remove bootstraped localbases.

4) A function to switch to a pkgsrc compiler instead of using the host compiler, and rebuild of all the packages that need that after a compiler switch. You should also be able to choose either a default compiler or one of your own choice from pkgsrc. ipp can also do this.

5) Generation of a custom mk.conf for different OS's. E.g. Illumos/Openindiana needs some tweaks in the mk.conf to get as many packages build as possible e.g. PREFER.sun-jre6=native. A standard mk.conf just won't do it.

6) Maybe more to come...

We also has promised Openindiana to provide a IPS repo of our builds. For this, it could be nice to have a pkgsrc2ips function build into the pkgsrc framework. At first we will provide our own script to do this, but it could be cool if it was a native pkgsrc function.

Mads Worsøe Duun
The Illumos Pkgsrc Project

Home | Main Index | Thread Index | Old Index