LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-03-2015, 03:16 PM   #1
hack3rcon
Senior Member
 
Registered: Jan 2015
Posts: 1,432

Rep: Reputation: 11
Post Installing program from source.


Hello.
For Installing program from source "/usr/local" is good or "/usr/local/src" ?

Thank you.
 
Old 07-03-2015, 04:00 PM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
No <options> : Programs will often by default install to /usr/local/.


/usr/local/src/ : Is never used. ( For anything.)
 
Old 07-03-2015, 06:48 PM   #3
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,624

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
if you are not going to provide any information !
there is not much we can do .

is it a "autotools" build ?

is it a "cmake" build ?

is it a "q-make" build ?

is it a "Makefile" build ?



for a Autotools build

read the configure "help" output
Code:
./configure --help

-------- the default location is likely the debian stile "/usr/local"
-------- for a RPM based distro use 

./configure --prefix=/usr
 
Old 07-03-2015, 08:20 PM   #4
Ranamon
Member
 
Registered: Feb 2013
Location: Land of Hopenchange
Distribution: Slackware
Posts: 45

Rep: Reputation: Disabled
Quote:
Originally Posted by hack3rcon View Post
Hello.
For Installing program from source "/usr/local" is good or "/usr/local/src" ?

Thank you.
Not enough information. Is this a snapshot you're getting off CVS or GIT? For that, I usually make a directory to receive the download. Once it's compiled and whipped into shape, then just run "make distcheck" on it and store the tar file (where ever you find that convenient).

Self written apps go into /usr/local for debug versions and testing. Once satisfied, I'll recompile, use the optimization flags, and drop it in /usr. That way, I know where the production runs are, and where the debug versions are.
 
Old 07-04-2015, 12:03 AM   #5
hack3rcon
Senior Member
 
Registered: Jan 2015
Posts: 1,432

Original Poster
Rep: Reputation: 11
No, It just a program from source code. For example, You want to install pidgin from source code. The better place is ".../src/" or ".../local" ?
 
Old 07-04-2015, 01:28 AM   #6
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,624

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
Quote:
For example, You want to install pidgin from source code. The better place is ".../src/" or ".../local" ?
nether but maybe /usr/local

BUT

it REALLY depends on your operating system and HOW !!! YOU !!! set it up

i build a LOT of programs but i keep them OUT!!!! of the default OS directory tree

i use a second tree for all the programs i build
( this way if i FUBAR the OS i can reinstall the os EASILY )

so is set my build path to "/DATA/SUSE "
Code:
./configure --prefix=/DATA/SUSE
this then causes "make install" to install it to
/DATA/SUSE/bin
/DATA/SUSE/lib64
/DATA/SUSE/include
/DATA/SUSE/share

some people like where Libreoffice installs
/opt/LibreOffice

some LIKE to use the "local"
this dates back to server / terminal of the 70's ,80's and early 90's
where the local directory WAS on your desk and "/" was on a server someplace


use what you want
but you might WANT to stay consistent and use that ALL the time
 
Old 07-04-2015, 02:02 AM   #7
JaseP
Senior Member
 
Registered: Jun 2002
Location: Eastern PA, USA
Distribution: K/Ubuntu 18.04-14.04, Scientific Linux 6.3-6.4, Android-x86, Pretty much all distros at one point...
Posts: 1,802

Rep: Reputation: 157Reputation: 157
If you want to be technical about it,... If you are installing programs manually, you should probably be installing them to /opt ... The /opt directory is supposed to be the place where software that is not part of the OS's standard installation is supposed to be done...

Then again,... nobody keeps to standards anymore (or never really did, for that matter)...
 
Old 07-04-2015, 05:36 AM   #8
hack3rcon
Senior Member
 
Registered: Jan 2015
Posts: 1,432

Original Poster
Rep: Reputation: 11
So, What is the purpose of "src" directory?
 
Old 07-04-2015, 10:18 AM   #9
mralk3
Slackware Contributor
 
Registered: May 2015
Distribution: Slackware
Posts: 1,901

Rep: Reputation: 1052Reputation: 1052Reputation: 1052Reputation: 1052Reputation: 1052Reputation: 1052Reputation: 1052Reputation: 1052
Quote:
Originally Posted by hack3rcon View Post
So, What is the purpose of "src" directory?
Use that one command, man.

Code:
man hier
Quote:
/usr/src
Source files for different parts of the system, included with some packages for reference purposes. Don't work here with your own projects, as files below
That same man page has all the relevant information you have been asking for.

EDIT: cleaned up text

Last edited by mralk3; 07-04-2015 at 08:01 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
list the steps for installing a program from source code kenholtmeyer Linux - Newbie 12 08-14-2011 09:40 PM
open source dvd/cd copy program? burning on the fly program? vieya Linux - Software 3 12-14-2009 09:16 PM
Installing from source, installing from CVS and the E-17 window manager... Buffbannana049 Ubuntu 10 02-14-2006 11:27 PM
looking for an open source program that can... Eugene Programming 6 11-13-2003 02:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:53 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration