Differences between revisions 2 and 3
Revision 2 as of 2013-06-10 15:17:40
Size: 1300
Editor: felixs
Comment: tiny functional fix
Revision 3 as of 2013-06-10 19:45:45
Size: 1301
Editor: felixs
Comment: interpreter added, don't know how to escape # correctly
Deletions are marked like this. Additions are marked like this.
Line 16: Line 16:
#!/whatever/make \#!/whatever/make

Currently each foreign package is adorned with a small program "spkg-install" that automates the compilation/installation of the package by calling the parts of the packages build system accordingly.

most implementations of this program (for the various packages) are purely monolithic, sequential and stateless. these programs need to be extended to allow

  • direct call of subroutines
  • basic dependency support (dont configure before patch etc.)
  • states, for example for patching, dont build twice etc.
  • support for FILELIST (record installed files) and DESTDIR (GNU standard)
  • uninstall, clean etc.
  • simple default subprograms for source or binary package creation (for other distributions)

a simple straigtforward replacement ("common practice") would be an executable makefile which has "install:" as its default target. such a makefile could look like very much like this

\#!/whatever/make
include /some/common/rules
PACKAGE_NAME=bla

configure:
    cd src; configure --prefix=... --something

install:
    $(MAKE) -Csrc install DESTDIR=$(DESTDIR) INSTALL=$(SAGE_INSTALL) -F $(FILELIST)

theoretically it can be implemented in any other language, we have interpreters for,

  • shell
  • python
  • ?

but this looks much more involved (example?)