Tuesday, July 3, 2012

Packager for binaries on any UNIX-compatible system


You may require to bundle the binaries built on any UNIX-compatible system for distribution.

For example, say, you have built a compiler using GCC compiler generation framework. And you need to distribute the built compiler binaries to some user. That means here you are required to distribute your gcc compiler installation directory to the user. How would you do that?

You can make a tar of the installation directory and distribute it to the user. But here you have to educate the user on how to untar and where to untar the provided tar file. And this way the user has to put some "extra" effort for using the binary distributed to him. Wouldn't it be better to provide the user with a self-extracting package of binaries?

Yes, you can provide the user with a self-extracting package of binaries. And the user has to just run it to extract the binaries into his desired directory. How to create a self-extracting package of binaries?

There is tool called "makeself". This is a very simple tool that does the job for you. Install this tool in your system and use it for creating the self-extracting package of binaries. For more information on "makeself", refer http://megastep.org/makeself/.

So for our example, assuming "myCompiler" as the installation directory to be distributed, create the self-extracting package "myCompiler.run" as follows:

makeself.sh --notemp myCompiler myCompiler.run "myCompiler generated from GCC framework" echo "myCompiler has been installed"

1 comment:

Tomminy said...

iDealshare VideoGo is just the right MKV to Sony Bravia TV Converter! Besides converting MKV to Sony TV format, it also supports converting other video like MOV, FLV, Xvid, AVI, RMVB, RM, TS, VOB, 3GP, 3G2, OGV, MVC, DV, MXF, and etc to Sony Bravia and other Sony TV model supported video format.https://www.idealshare.net/video-converter/play-mkv-on-sony-bravia-tv.html