You are not logged in.

#1 2008-09-03 18:41:32

farvardin
Member
Registered: 2008-09-03
Posts: 120
Website

Reason for software in opt?

Hello,

is there a reason and a logic why some software are located into /opt while other aren't ?

I usually put into /opt the software I've downloaded and installed myself (like firefox, planeshift or xsteem) , and keep it into a separate partition so I can access it from several linux distributions.

opt seems to stand for "optional application software packages". On some other sources, it's reserved for "add-on application software packages" ( http://www.pathname.com/fhs/2.2/fhs-3.12.html )

For example, why Kde into /opt, and not Gnome? Why java, virtualbox, openoffice and qt, and not the flash plugin or freemind?

Offline

#2 2008-09-03 18:44:41

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 3,682

Re: Reason for software in opt?

Mostly big self-contained things were put there. gnome has been already pulled out, kde4 and qt4 aren't there anymore either. There have been countless topics about /opt, just search the forum.

Offline

#3 2008-09-03 19:52:50

carlocci
Member
From: Padova - Italy
Registered: 2008-02-12
Posts: 368

Re: Reason for software in opt?

software you installed by yourself should go in /usr/local.

Offline

#4 2008-09-03 21:13:37

farvardin
Member
Registered: 2008-09-03
Posts: 120
Website

Re: Reason for software in opt?

lucke wrote:

There have been countless topics about /opt, just search the forum.

opt is such a short word and commonly used there are 300 pages of topics related to this. I've tried to add other keywords but really nothing much relevant came.

/usr/local is ok for self compiled software, but I prefer to keep precompiled binaries software into /opt

Offline

#5 2008-09-03 22:37:35

carlocci
Member
From: Padova - Italy
Registered: 2008-02-12
Posts: 368

Re: Reason for software in opt?

farvardin wrote:

/usr/local is ok for self compiled software, but I prefer to keep precompiled binaries software into /opt

IMHO that's exactly what /opt is for: software which was compiled by 3d parties.
/opt is C:\Program Files

Offline

#6 2008-09-03 22:50:16

freakcode
Member
From: São Paulo - Brazil
Registered: 2007-11-03
Posts: 410
Website

Re: Reason for software in opt?

Putting simple: /opt is for 3rd party stuff that may not follow the /usr directory layout (bin, etc, lib, share...).

For example, a hipotetical software package that installs itself in Linux way would place files into this layout:

/usr/bin/myapp
/usr/lib/myapp/libfoo.so
/usr/lib/myapp/libfoo.so.1
/usr/share/myapp/myfooicon.png

If there's a 3rd party package that doesn't follow this layout, then it should be put under the /opt tree

/opt/myweirdapp/Exec/myappbin
/opt/myweirdapp/Libraries/myapplib.so
/opt/myweirdapp/Documentation/myapplmanual.pdf

There's /opt/bin and /opt/lib though, that are intended to be under your PATH, so users can call binaries without going inside the application tree for each application, which is, of course, non-standard (e.g., /opt/myweirapp/Exec/myappbin)

More info:
http://www.pathname.com/fhs/pub/fhs-2.3 … REPACKAGES

Offline

#7 2008-09-03 23:13:07

Misfit138
Misfit Emeritus
From: USA
Registered: 2006-11-27
Posts: 4,167
Website

Re: Reason for software in opt?

Beginners' Guide explanation:

/opt/  Packages that do not fit cleanly into the above GNU filesystem layout can be placed here. If a package's files cannot be cleanly placed into the above directories, then /opt shall be used. /opt shall therefore contain shareable data.

For example, the acrobat package has Browser, Reader, and Resource directories sitting at the same level as the bin directory. This doesn't fit into a normal GNU filesystem layout, so Arch places all the files in a subdirectory of /opt.

Offline

#8 2008-09-04 07:53:29

ornitorrincos
Forum Fellow
From: Bilbao, spain
Registered: 2006-11-20
Posts: 194
Website

Re: Reason for software in opt?

I also use it if the package conflicts with an already existing package.


-$: file /dev/zero
/dev/zero: symbolic link to '/dev/brain'

Offline

#9 2008-09-04 12:14:46

Dusty
Schwag Merchant
From: Medicine Hat, Alberta, Canada
Registered: 2004-01-18
Posts: 5,986
Website

Re: Reason for software in opt?

Traditionally, they put difficult or weird applications in /opt just because it was easier to package that way (it was self contained.) The packaging standards have changed, so new packages do not go in /opt.

Many large apps have moved to the standard hierarchy, but some stay in /opt because nobody has taken the time to port them. The specific apps you mention are either a) difficult to move to a standard hierarchy (oo.o, kde) or b) maintained by one of the devs who doesn't have much time for Arch lately (Java).

/opt is a system folder, its not really meant to have user-created packages in it. In general, only /etc, /usr/local, /usr/src, /boot, and /home should contain files that have been changed by the user or sysadmin. In practice, of course, this is not a rule and should always be broken.

Dusty

Offline

#10 2008-09-04 18:16:48

farvardin
Member
Registered: 2008-09-03
Posts: 120
Website

Re: Reason for software in opt?

Thank you all for the complete explanations!

Offline

Board footer

Powered by FluxBB