Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Anyone know how to write a UNIX install script?

Status
Not open for further replies.

TheBrewer

Programmer
Jun 29, 2000
3
0
0
US
Here's the situation, I'm fresh out of school with little if any unix experience.  My supervisor wants me to write an install script to aid in the deployment of our application.  From what I know of unix, this would require three different scripts, because we have SGIs, HPs, and Suns, all with different shells, but I have no idea what goes into writing a script, especially an install script.  Does anyone have any idea how to go about doing this, or where to look this stuff up on the web?<br><br>Pete
 
Pete,<br><br>This is quite a large question but I can, I think, suggest some areas for you to look at.<br><br>1 - I think you'll find that the bourne shell and the korn shell are available on all three platforms. My reccomendation would be the korn shell because some things are easier using ksh than sh. Go and have a look at &quot;Learning the Korn Shell&quot; ISBN 1-56592-054-6.<br><br>2 - What's the application written in? If it's C you'll need to compile a different version of the binaries for each platform. (You could still have just the one install script though....)<br><br>3 - Break the job into manageable peices.<br><br>&nbsp;3.1 &quot;Make a Release&quot; by collecting the s/w together and storing a snapshot of it in an archive file (look at the tar command for that) this archive should contain everything you need <br><br>&nbsp;3.2 &quot;Where the hell am I?&quot; Make sure your install script can detect what it is running on and make some appropriate decisions based on that (install the SGI binaries on an SGI machine for instance)<br><br>&nbsp;3.3 &quot;Where does this bit go?&quot; Allow your users, who are running the install script (might be you) to decide where the s/w is going when they install it.<br><br>So. Go and buy the book from Amazon. Look up the tar command. If you can, do an install of Perl on a Unix machine; that will give you some ideas on what an install routine might do. <p>Mike<br><a href=mailto:michael.j.lacey@ntlworld.com>michael.j.lacey@ntlworld.com</a><br><a href= Cargill's Corporate Web Site</a><br>
 
I don't know how &quot;fancy&quot; you want to get, but Loki have just released their setup software as Open Source.&nbsp;&nbsp;It gives a graphical install front end using GTK.&nbsp;&nbsp;In the freshmeat.net announcement, it stated that it ran on Sun, but didn't mention HP or SGI.&nbsp;&nbsp;However, you may be able to port the software without too much problem.&nbsp;&nbsp;Or you may not ;^)&nbsp;&nbsp;Hope it helps though. <p> <br><a href=mailto: > </a><br><a href= > </a><br>--<br>
0 1 - Just my two bits
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top