Subject: Re: pkgsrc option to install all mk-files
To: Simon Gerraty <sjg@juniper.net>
From: Jeremy C. Reed <reed@reedmedia.net>
List: tech-pkg
Date: 05/05/2004 16:33:00
On Wed, 5 May 2004, Simon Gerraty wrote:
> On Wed, 5 May 2004 15:48:17 -0700 (PDT), "Jeremy C. Reed" writes:
> >I see that mk-files has an install-mk and an auto PLIST generation
> >for choosing what mk files to install.
>
> My initial reaction is that a binary package of mk-files is a bad
> idea.
>
> If you want to do a binary package though I think it would be
> best to use Generic.sys.mk which will attempt to include the OS
> sepcific sys.mk - it probably needs more work btw ;-)
>
> >The README.1st says:
> >
> > The *.sys.mk files should be installed as sys.mk on the appropriate
> > machine.
> >
> >But as you can see above I have nothing to symlink my sys.mk to.
>
> Yep, the auto PLIST thing isn't quite what you want - I've not looked
> at that bit for years. I'm pretty sure it pre-dates install-mk
>
> >I don't know why I don't have the many per operating system files.
>
> Because you probably built the pkg on a BSD system.
I built the package on a Linux system and copied it over to another Linux
system. Everything is from pkgsrc.
> >I see a FORCE_SYS_MK. Can we have some option that always enables this to
> >do a symlink?
> >
> >Will it break some systems to always install all mk files to /usr/pkg and
> >to automatically make a new symlink at /usr/pkg/mk/sys.mk ?
>
> None of these will DTRT on all platforms, generally on a bsd system
> you want to use /usr/share/mk/bsd.* and install-mk can arrange to make
> symlinks to them - but that's not suitable for a binary package.
I forgot to mention the bsd.* scripts too. They are used by a very few
source available via pkgsrc using their own makefiles. My working Linux
system has:
lrwxrwxrwx 1 root root 6 Oct 13 2003 bsd.dep.mk -> dep.mk
lrwxrwxrwx 1 root root 6 Oct 13 2003 bsd.doc.mk -> doc.mk
lrwxrwxrwx 1 root root 7 Oct 13 2003 bsd.init.mk -> init.mk
lrwxrwxrwx 1 root root 6 Oct 13 2003 bsd.lib.mk -> lib.mk
lrwxrwxrwx 1 root root 6 Oct 13 2003 bsd.man.mk -> man.mk
lrwxrwxrwx 1 root root 6 Oct 13 2003 bsd.nls.mk -> nls.mk
lrwxrwxrwx 1 root root 6 Oct 13 2003 bsd.obj.mk -> obj.mk
lrwxrwxrwx 1 root root 6 Oct 13 2003 bsd.own.mk -> own.mk
lrwxrwxrwx 1 root root 7 Oct 13 2003 bsd.prog.mk -> prog.mk
lrwxrwxrwx 1 root root 9 Oct 13 2003 bsd.subdir.mk -> subdir.mk
I am not sure why this is not suitable for a package. Will you explain?
Also, my working Linux system has:
-rw-rw-r-- 1 reed root 3477 Sep 30 2003 AIX.sys.mk
-rw-r--r-- 1 reed root 3605 Sep 30 2003 Darwin.sys.mk
-rw-rw-r-- 1 reed root 3990 Sep 30 2003 Generic.sys.mk
-rw-rw-r-- 1 reed root 4557 Sep 30 2003 HP-UX.sys.mk
-rw-r--r-- 1 reed root 3570 Sep 30 2003 IRIX.sys.mk
-rw-rw-r-- 1 reed root 3627 Oct 13 2003 Linux.sys.mk
-rw-rw-r-- 1 reed root 3934 Sep 30 2003 NetBSD.sys.mk
-rw-rw-r-- 1 reed root 3819 Sep 30 2003 OSF1.sys.mk
-rw-r--r-- 1 reed root 3680 Sep 30 2003 OpenBSD.sys.mk
-rw-rw-r-- 1 reed root 3478 Sep 30 2003 SunOS.4.sys.mk
-rw-rw-r-- 1 reed root 3768 Sep 30 2003 SunOS.5.sys.mk
and
lrwxrwxrwx 1 root root 12 Oct 13 2003 sys.mk -> Linux.sys.mk
If some of these things should not be installed in your package, then I
will make a variable like MK_FILES_INSTALL_ALL and if defined then really
do install all and symlink for the sys.mk.
> >Also, can we have the package install the README too?
>
> Sure.
>
> >I will do this coding if you have any suggestions or advice about this
> >first.
>
> Feel free - you'll probably make less of a mess than I would ;-)
Any more suggestions before I bite into this?
Jeremy C. Reed
BSD News, BSD tutorials, BSD links
http://www.bsdnewsletter.com/