Install linux package from source.

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Install linux package from source.

ubuntu-users mailing list
Hello I am wanting to install a package from source on ubuntu mate. From what I understand I use ./configure.    Then make but my question is where is this package installing? Is it installing to a default location specified by the develper? Is their an option that lets me install it to my directory and if so what is a good directory to install programs?
--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
Reply | Threaded
Open this post in threaded view
|

Re: Install linux package from source.

Peter Flynn
On 15/02/2021 22:22, M.R.P. zensky via ubuntu-users wrote:
> Hello I am wanting to install a package from source on ubuntu mate.
> From what I understand I use ./configure.    Then make but my
> question is where is this package installing? Is it installing to a
> default location specified by the develper? Is their an option that
> lets me install it to my directory and if so what is a good directory
> to install programs?

Look at Makefile. it should say in there where the default installation
directory is.

For add-on software, the traditional place is /usr/local/bin for the
program and /usr/local/lib for any libraries.

Look at the README file, it should say what option is used to change the
installation directory.

--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
Reply | Threaded
Open this post in threaded view
|

Re: Install linux package from source.

ubuntu-users mailing list
On Mon, 15 Feb 2021 23:35:50 +0000, Peter Flynn wrote:

>On 15/02/2021 22:22, M.R.P. zensky via ubuntu-users wrote:
>> Hello I am wanting to install a package from source on ubuntu mate.
>> From what I understand I use ./configure.    Then make but my
>> question is where is this package installing? Is it installing to a
>> default location specified by the develper? Is their an option that
>> lets me install it to my directory and if so what is a good directory
>> to install programs?  
>
>Look at Makefile. it should say in there where the default
>installation directory is.

Hi,

you can chose a path, when you configure, e.g.

  ./configure --prefix=/usr

so bin/ will be /usr/bin, lib will be /usr/lib etc. or

  ./configure --prefix=/usr/local

which installs bin/ to /usr/local/bin etc. or chose any other prefix
path.

However, "make install" does _not_ install a package. It installs the
files without a package, that would be manageable by a package manager.

There are different ways to build and install a package. The
easiest, but not necessarily the best way is to replace "make install"
by "checkinstall" [1].

Regards,
Ralf

[1]
https://packages.ubuntu.com/groovy/checkinstall

--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
Reply | Threaded
Open this post in threaded view
|

Re: Install linux package from source.

ubuntu-users mailing list
On Tue, 16 Feb 2021 03:23:51 +0100, Ralf Mardorf wrote:
>>On 15/02/2021 22:22, M.R.P. zensky via ubuntu-users wrote:  
>>> what is a good directory to install programs?    

PS: On Linux consider to install your local builds to

>  ./configure --prefix=/usr/local

    Consider to avoid this on FreeBSD. Even on Linux another common
    path for local builds is /opt. When I build local Linux packages, I
    sometimes prefer /usr over /usr/local. Without building a package I
    recommend to install to /usr/local or /opt.

    Since you are unfamilar with building from source, consider to
    mention what you want to build and install, since you might risk to
    mess up your install. Just imagine you build and overwrite
    "libfoo.so.1", while your "libfoo.so.1" isn't patched, but Ubuntu's
    "libfoo.so.1" is patched for good reasons. Or you build
    "libbar.so.2", but your Ubuntu does require "libbar.so.1". As long
    as you keep "libbar.so.1" everything is ok, but if a package gets
    replaced and should remove "libbar.so.1" you would break your
    Ubuntu install or if you one day would rebuild an Ubuntu package
    that should build against "libbar.so.1", you need to check first
    against what version libbar.so does link.

    Is the source secure? If so, did you check the downloaded source
    against a _signed_ checksum (not just a checksum)?

    If the software you want to build from source isn't available by
    Ubuntu repositories, did you check what's the reason for this.

    An example, https://packages.ubuntu.com/xenial/libwebkitgtk-1.0-0
    is available for Ubuntu 16.04 and 18.04, but not for >= 20.04.
    There could be different reasons for discontinued or never provided
    packages. One reason is security. You shouldn't build vulnerable
    software such as this outdated webkit for Ubuntu installs >= 20.04,
    instead you should purge it from Ubuntu 16.04 and 18.04 installs.

--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
Reply | Threaded
Open this post in threaded view
|

Re: Install linux package from source.

Robbi Nespu
In reply to this post by ubuntu-users mailing list
On 16/2/2021 6:22 am, M.R.P. zensky via ubuntu-users wrote:
> Hello I am wanting to install a package from source on ubuntu mate. From what I understand I use ./configure.    Then make but my question is where is this package installing? Is it installing to a default location specified by the develper? Is their an option that lets me install it to my directory and if so what is a good directory to install programs?
>

What package you want to install?

If the Makefile is generated by GNU autotools (normally), you can set
where you want to install using these command

./configure --prefix=/somewhere/else/than/usr/local

else, just open the source file or makefile and change the location as
it could be define somewhere inside.

--
Email: Robbi Nespu <robbinespu AT SPAMFREE gmail DOT com>
PGP fingerprint : D311 B5FF EEE6 0BE8 9C91 FA9E 0C81 FA30 3B3A 80BA
PGP key : https://keybase.io/robbinespu/pgp_keys.asc

--
ubuntu-users mailing list
[hidden email]
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users