-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 04/10/2010 06:25 PM, Stuart Henderson wrote: > On 2010-04-10, Aaron Lewis <aaron.lewis1...@gmail.com> wrote: >> >> Hi, >> I'm trying to make a small binary package , which aims to install some >> X11 fonts to /usr/share/fonts/truetype. > > /usr/share/fonts/truetype -> not portable > >> Creating such a binary package will allow me to port it on any >> UNIX/Linux system , very useful. >> >> Firstly i need to compress my fonts to a Font_Name.tar.bz2 , if i want >> to put the extract script and Font_Name.tar.bz2 together , a single >> bundle , howto archive it ? >> >> Right now , i tried to append the Archive to the script file , Then try >> to read through the `setup file' except for the first 5 lines. >> >> #!/bin/bash > > /bin/bash -> not portable
Oops , my linux background .. you're right Stuart. > >> tail +5 $0 | tar xvf - -C /tmp >> exit 0 >> #======================== >> //Append Tar.Bz2 file > > bz2 -> not as portable as it could be > > relying on tar to autodetect compressed archives -> not portable > > running some random downloaded shell archive with sufficient > permissions to install to /usr/share without a good way to inspect > what it's going to overwrite -> not safe > >> Doesn't looks like a good way , anyone could help ? > > the simple portable safe way is a tar.gz with a README and ideally > a Makefile. people know how to use these. use a variable for the install > target so people can override it on the make(1) command line. Makefile + ReadMe is yet another good way. Put different entries based on different OS , and people just override Makefile command line. I've similar things before e.g make openbsd make solaris make linux .. Simpler is easier anyway ;-) Thanks to all of you. - -- Best Regards, Aaron Lewis - PGP: 0x4A6D32A0 FingerPrint EA63 26B2 6C52 72EA A4A5 EB6B BDFE 35B0 4A6D 32A0 irc: A4r0n on freenode Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkvAVdYACgkQvf41sEptMqD36gCg2PYIlMjNBwhx6zS2rblyEyoJ LXgAoJDKuYwXKLoJ5Vj+D69DJ2aROJv5 =LWAY -----END PGP SIGNATURE-----