2

I have installed the GNU "core" utilites coreutils-8.21 into this location on my UNIX server:

/opt/app/p1sas1c1/apps/GNU

I would now like to ADD the findutils-4.4.2 package. My reading the INSTALL document, I see I can configure using this command:

./configure --prefix=/opt/app/p1sas1c1/apps/GNU

That is the same "prefix" I used to install the core utilities.

My question is: If I do this and follow with a "make install" command, will that over-write the existing files in that target location or just "add" the new elements into the corresponding directories?

I want to check first on the "best practices" for doing things like this. I am not a trained "SA" and do not have "root" access; I'm using an application account to do the install.

  • 1
    I know this is not an answer but I do not understand how your Solaris SysAdmin could dream of giving you a box where this is not already installed. I see the same questions over and over again on this and other sites and for this reason I've created this. Hope to change some SysAdmins. Point being is that you shouldn't have to fiddle with installing 'standard' stuff like GNU findutils on Solaris. It should just be there! – unixhacker2010 Oct 04 '13 at 10:02
  • @unixhacker2010 Very useful to me; unfortunately, in our "corporate environment", our SysAdmins are only allowed to install "standard approved software" and unless it's part of the standard deployment, applications must install other things themselves (often by untrained people like myself). According to another comment, all of this is in Solaris 11, but I'm on Solaris 10 right now. Solaris 11 is not yet "approved". – BellevueBob Oct 04 '13 at 15:02
  • I understand. The tools I mention on the link used in fact to be distributed by Sun on a separate CD/DVD called Solaris Companion Disk. This meant that the most SysAdmins felt ok to install it. However at some point Sun unfortunately handed over the responsibility for that collection to SunFreeware - which is not affiliated with Sun (Oracle), that is they are an outsider. In Solaris 11 it is all fixed as explained in the link. – unixhacker2010 Oct 07 '13 at 14:28
  • http://www.gnu.org/software/stow/ might help you solve this problem of managing the packages in /opt/blabla – James Youngman Feb 29 '16 at 15:46

2 Answers2

5

make install will overwrite existing files by the same name. Other than that, it will not remove existing files. GNU coreutils and GNU findutils are intended to be used and installed alongside each other, so they don't have different files by the same name. Therefore if you install them one after the other, you'll get both.

  • This makes sense after I think about it more; after all, the default writes to /usr/local so it would not overwrite everything. Never doing this before caused me to ask. – BellevueBob Oct 04 '13 at 14:55
4

Yes the make install will overwrite any preexisting files that are there, assuming you have write access to that target location. But given these packages are all part of the same "system" I'd be inclined to think that it's modular in nature and that it's doing the installations into the same prefix in a controlled fashion, and won't be overwriting anything, as you install subsequent pieces.

My advice would be to do a test first to see what will actually get installed prior to doing so. You can change the --prefix to anything you like, so long as you have write access to that directory.

Additionally:

  • Why are you not using your Linux distributions package management to do this?
  • Are you installing a newer version that isn't available?
  • Or are you simply learning?

Whatever the reason I would consider the ramifications of installing software as a custom "thing" vs. using packages. Yes you can do either, but there are trade-offs with doing a custom installation of software vs. using the stock off the shelf variety that is provided by your distributions package manager.

Custom affords you full control, but with the price of having to keep it current, and having to know how to build it and care for it.

Off the shelf provides you with convenience, but now you're dependent on someone else to care for the software, and you're locked into their schedule.

Choose wisely!

slm
  • 369,824
  • I'm on Solaris, not Linux. 2) I'm trying to ADD these "findutils" to my system; I could install them into a clean directory but thought is made sense to add them into my "standard" GNU directory 3) Not really "just learning". I need the GNU find command for a script (actually just the -maxdepth option).
  • – BellevueBob Oct 03 '13 at 22:02
  • Solaris does have a package manager too. Install them into your own home directory if you're the only one that will use them, if they are used by cron and other accounts then they go into /opt or /usr/local/bin. – slm Oct 03 '13 at 22:21
  • 1
    sunfreeware.com died (or went paid subscription only) several years ago, but you can still find pre-packaged GNU software for Solaris at http://www.opencsw.org/ – cas Oct 04 '13 at 02:35
  • If you're on Solaris 11 then GNU findutils is installed by default but does not make it by default into a local zone. See this posting for more info. – unixhacker2010 Oct 04 '13 at 10:06