LinuxQuestions.org
Visit Jeremy's Blog.
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 05-22-2017, 04:22 AM   #1
FranekW
Member
 
Registered: Apr 2017
Distribution: Manjaro and Ubuntu
Posts: 30

Rep: Reputation: Disabled
Usage of configure during non-standard installation


I am a newbie when it comes to Linux but not completely lost I installed CentOS 7 a couple of weeks ago because this is what I have at uni. I have already managed to install a couple of applications, created a few custom icons in my Show Application but I am currently struggling to install GnuGP 2.1.12. Normally I would go for `yum install <app>` but this and a lot of other applications on CentOS 7 are outdated, e.g. git 1.8.x.

Installing GnuGP 2.1.21 (link) from sources requires to handle a bunch of dependencies which are also available on the same website. I guess if I used the default sequence below to each of the dependencies:

Code:
./configre
make
sudo make install
I would be fine but I don't really want to mess with /usr/*/bin folder which I think is maintained by yum.

I have already read how to install application (here) but I would like to choose a custom folders for that, e.g. /opt. How should I proceed. Aforementioned dependencies will most likely be installed as libraries, include files etc. which GnuGP needs to function. I would like all of them to be installed in custom folders, somewhere away from system folders. Is it possible? If yes, would it be really hard to do? I have noticed ./configure accepts a lot of options, such as --prefix but I guess I need more than that, especially when it comes to locate custom libraries/extra files etc.

Thanks.
 
Old 05-22-2017, 07:21 AM   #2
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,876
Blog Entries: 13

Rep: Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930
One suggested step by their documentation is that you should run autogen.sh:
Code:
./autogen.sh
Based on the outcome of that it will recommend possible arguments for the ./configure step.

I don't understand your concerns about the /usr/bin, /usr/sbin tree, this is what it is there for. Installing the formal binaries for common applications.

When you perform yvm install <app>, it usually places the executable images in any of: /bin, /sbin, /usr/bin, or /usr/sbin
 
Old 05-22-2017, 08:18 AM   #3
FranekW
Member
 
Registered: Apr 2017
Distribution: Manjaro and Ubuntu
Posts: 30

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by rtmistler View Post
I don't understand your concerns about the /usr/bin, /usr/sbin tree, this is what it is there for. Installing the formal binaries for common applications.

When you perform yvm install <app>, it usually places the executable images in any of: /bin, /sbin, /usr/bin, or /usr/sbin
I am afraid that if something wrong happens and I have already used default system folders for dependencies, I won't be able to recover from it and revert back where I was. For instance, CentOS has gpg2 already installed via yum install gpg2, which is an old version and use deprecated system of managing security keys. If I perform this installation using default system folders, I will very likely overwrite something that is already installed, e.g. original files regarding gpg2.

I don't know how to check things like this and do any precautions in case things have gone wrong. I would probably have to reinstall the system.
 
Old 05-22-2017, 08:34 AM   #4
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,876
Blog Entries: 13

Rep: Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930
You can uninstall the new one and then re-install the former one using the yvm method. What you can do in the forward direction, you can do in the reverse direction.
 
Old 05-22-2017, 08:45 AM   #5
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
as far as backing off and resetting to where it was before you ran the
Code:
./configure
make
#make install
if that configure is not setup with an uninstall script within its bundle then it is manually removing of same said item. if all it did was add an executable within your bin then just delete it. if it installed much more than that then you have to track it down and delete it manually. this should not bother your system as long as other "apps" are not depending on anything it is giving.

if by chance it was, then just re-install it the same way you did the first time. that should fix it.

Where you are wanting to put everything you do using ./configure into /opt just to play it safe is a can do thing. then you're going to have to learn how to make your system look in there every time it is wanting to use something that usually goes into one of the bins or else where within the system which could get complected but it is still a possibility.

with Slack or Void Linux one just makes a script then run it so that system then can take care of it. It knows where it is at if one wants to upgrade or remove same said item then simply use that 'custom' script to do so. Makes life using Linux/GNU a bit easier when installing outside of the repo.

Last edited by BW-userx; 05-22-2017 at 08:53 AM.
 
Old 05-22-2017, 11:08 AM   #6
FranekW
Member
 
Registered: Apr 2017
Distribution: Manjaro and Ubuntu
Posts: 30

Original Poster
Rep: Reputation: Disabled
Are you sure I can install GnuGP using default options? I just want to point out that GPG2 in CentOS seems a special protected application because YUM somehow uses for its own purpose. I am still not convinced if I should do it!

BTW, thanks for your comments
 
Old 05-22-2017, 11:23 AM   #7
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
what is the worst case scenario if you install it and it does a ka pow on ya?
Are you able to recover from this worst case scenario?
if yes, Then what was so bad about it that it stopped you from finding out first hand?

Last edited by BW-userx; 05-22-2017 at 11:24 AM.
 
1 members found this post helpful.
Old 05-22-2017, 11:42 AM   #8
DavidMcCann
LQ Veteran
 
Registered: Jul 2006
Location: London
Distribution: PCLinuxOS, Debian
Posts: 6,131

Rep: Reputation: 2302Reputation: 2302Reputation: 2302Reputation: 2302Reputation: 2302Reputation: 2302Reputation: 2302Reputation: 2302Reputation: 2302Reputation: 2302Reputation: 2302
Stop! Right now!

The point about enterprise-class distros is that they go for tried-and-tested rather than bleeding-edge. If Red Hat (and that's what your CentOS is) gives you a particular version of GnuPG, that is proof enough that the version in question is adequate. "Updating" can (and probably will) break things. If a program has a security fault, then Red Hat back-port the solution, incorporating the patch issued for the newer version into the one they use.

On the general question of adding things to CentOS, read this
http://wiki.centos.org/AdditionalResources/Repositories
and this
http://wiki.centos.org/PackageManagement/Yum/Priorities
If you obey the rules, then you can install extra software safely; if you don't, then the only guarantee is that if it breaks you get to keep the pieces.
 
Old 05-22-2017, 11:43 AM   #9
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,876
Blog Entries: 13

Rep: Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930
Quote:
Originally Posted by BW-userx View Post
what is the worst case scenario if you install it and it does a ka pow on ya?
Are you able to recover from this worst case scenario?
if yes, Then what was so bad about it that it stopped you from finding out first hand?
And this is also not so non-standard. It's not like you're trying to install 10 year old software into an updated OS, you're just trying to install a new experimental release of this software, I believe.

A "data part" system backup is a good idea.

I also feel that one worst is that a few things need to be fixed, rather than the entire system be messed up to be unusable.
 
Old 05-22-2017, 11:47 AM   #10
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by rtmistler View Post
And this is also not so non-standard. It's not like you're trying to install 10 year old software into an updated OS, you're just trying to install a new experimental release of this software, I believe.

A "data part" system backup is a good idea.

I also feel that one worst is that a few things need to be fixed, rather than the entire system be messed up to be unusable.
I never told him to DO IT --
just gave him something to think about. He then needs to weigh out everything before making that decision.

worst case then is re-install lessened learned. carry on smartly.
 
Old 05-22-2017, 11:48 AM   #11
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,609
Blog Entries: 4

Rep: Reputation: 3905Reputation: 3905Reputation: 3905Reputation: 3905Reputation: 3905Reputation: 3905Reputation: 3905Reputation: 3905Reputation: 3905Reputation: 3905Reputation: 3905
If you want to experiment with other versions of software, the most-important consideration is your target. Do not allow the configure/make scripts to target the "usual" system-level directories. Do not invoke "root" privileges. Do not do anything that might require them.

You should, instead, target a private directory that is intended for such purposes, such as /usr/local. Or, put it somewhere else altogether. The distro's packaging subsystem will be unaware (and, unconcerned) of its existence. It's a good idea to place it somewhere such that intended users of the package must add the location to their $PATH, e.g. by adding a statement to their .bash_profile.

Last edited by sundialsvcs; 05-22-2017 at 11:50 AM.
 
Old 05-22-2017, 03:44 PM   #12
FranekW
Member
 
Registered: Apr 2017
Distribution: Manjaro and Ubuntu
Posts: 30

Original Poster
Rep: Reputation: Disabled
Hi,

I have installed GnuPG 2.1.12 and it works. Based on a script made by someone else, I have made the one below. Doing it manually would be very easy to make mistake, which I have probably made before :/ Now, everything has been installed and works ok. I have one only problem. I tried to verify signature files but I have got errors and I had to comment that block. Do you know why I have got errors?

Thanks

The code.

Code:
#!/bin/bash
 
CD=$(pwd)
 
mkdir --parents /opt/homeusr/gpg-install && \
cd /opt/homeusr/gpg-install && \
 
wget -c https://www.gnupg.org/ftp/gcrypt/gnupg/gnupg-2.1.21.tar.bz2 && \
wget -c https://www.gnupg.org/ftp/gcrypt/gnupg/gnupg-2.1.21.tar.bz2.sig && \
wget -c https://www.gnupg.org/ftp/gcrypt/libgpg-error/libgpg-error-1.27.tar.bz2 && \
wget -c https://www.gnupg.org/ftp/gcrypt/libgpg-error/libgpg-error-1.27.tar.bz2.sig && \
wget -c https://www.gnupg.org/ftp/gcrypt/libgcrypt/libgcrypt-1.7.6.tar.bz2 && \
wget -c https://www.gnupg.org/ftp/gcrypt/libgcrypt/libgcrypt-1.7.6.tar.bz2.sig && \
wget -c https://www.gnupg.org/ftp/gcrypt/libassuan/libassuan-2.4.3.tar.bz2 && \
wget -c https://www.gnupg.org/ftp/gcrypt/libassuan/libassuan-2.4.3.tar.bz2.sig && \
wget -c https://www.gnupg.org/ftp/gcrypt/libksba/libksba-1.3.5.tar.bz2 && \
wget -c https://www.gnupg.org/ftp/gcrypt/libksba/libksba-1.3.5.tar.bz2.sig && \
wget -c https://www.gnupg.org/ftp/gcrypt/npth/npth-1.4.tar.bz2 && \
wget -c https://www.gnupg.org/ftp/gcrypt/npth/npth-1.4.tar.bz2.sig && \
wget -c https://www.gnupg.org/ftp/gcrypt/ntbtls/ntbtls-0.1.1.tar.bz2 && \
wget -c https://www.gnupg.org/ftp/gcrypt/ntbtls/ntbtls-0.1.1.tar.bz2.sig && \
wget -c https://www.gnupg.org/ftp/gcrypt/pinentry/pinentry-1.0.0.tar.bz2 && \
wget -c https://www.gnupg.org/ftp/gcrypt/pinentry/pinentry-1.0.0.tar.bz2.sig && \
wget -c https://www.gnupg.org/ftp/gcrypt/gpgme/gpgme-1.9.0.tar.bz2 && \
wget -c https://www.gnupg.org/ftp/gcrypt/gpgme/gpgme-1.9.0.tar.bz2.sig && \
wget -c ftp://ftp.gnu.org/gnu/ncurses/ncurses-6.0.tar.gz
wget -c ftp://ftp.gnu.org/gnu/ncurses/ncurses-6.0.tar.gz.sig
 
#gpg --verify libgpg-error-1.27.tar.bz2.sig && \
#gpg --verify libgcrypt-1.7.6.tar.bz2.sig && \
#gpg --verify libassuan-2.4.3.tar.bz2.sig && \
#gpg --verify libksba-1.3.5.tar.bz2.sig && \
#gpg --verify npth-1.4.tar.bz2.sig && \
#gpg --verify ntbtls-0.1.1.tar.bz2.sig && \
#gpg --verify pinentry-1.0.0.tar.bz2.sig && \
#gpg --verify gpgme-1.9.0.tar.bz2.sig && \
#gpg --verify gnupg-2.1.21.tar.bz2.sig && \
#gpg --verify ncurses-6.0.tar.gz.sig && \
 
tar -xjf libgpg-error-1.27.tar.bz2 && \
tar -xjf libgcrypt-1.7.6.tar.bz2 && \
tar -xjf libassuan-2.4.3.tar.bz2 && \
tar -xjf libksba-1.3.5.tar.bz2 && \
tar -xjf npth-1.4.tar.bz2 && \
tar -xjf ntbtls-0.1.1.tar.bz2 && \
tar -xzf ncurses-6.0.tar.gz && \
tar -xjf pinentry-1.0.0.tar.bz2 && \
tar -xjf gpgme-1.9.0.tar.bz2 && \
tar -xjf gnupg-2.1.21.tar.bz2 && \
 
rm libgpg-error-1.27.tar.bz2 && \
rm libgpg-error-1.27.tar.bz2.sig && \
rm libgcrypt-1.7.6.tar.bz2 && \
rm libgcrypt-1.7.6.tar.bz2.sig && \
rm libassuan-2.4.3.tar.bz2 && \
rm libassuan-2.4.3.tar.bz2.sig && \
rm libksba-1.3.5.tar.bz2 && \
rm libksba-1.3.5.tar.bz2.sig && \
rm npth-1.4.tar.bz2 && \
rm npth-1.4.tar.bz2.sig && \
rm ntbtls-0.1.1.tar.bz2 && \
rm ntbtls-0.1.1.tar.bz2.sig && \
rm pinentry-1.0.0.tar.bz2 && \
rm pinentry-1.0.0.tar.bz2.sig && \
rm gpgme-1.9.0.tar.bz2 && \
rm gpgme-1.9.0.tar.bz2.sig && \
rm gnupg-2.1.21.tar.bz2 && \
rm gnupg-2.1.21.tar.bz2.sig && \
rm ncurses-6.0.tar.gz && \
rm ncurses-6.0.tar.gz.sig && \
 
cd libgpg-error-1.27 && ./configure && make && make install && cd ../ && \
cd libgcrypt-1.7.6 && ./configure && make && make install && cd ../ && \
cd libassuan-2.4.3 && ./configure && make && make install && cd ../ && \
cd libksba-1.3.5 && ./configure && make && make install && cd ../ && \
cd npth-1.4 && ./configure && make && make install && cd ../ && \
cd ntbtls-0.1.1 && ./configure && make && make install && cd ../ && \
cd ncurses-6.0 && ./configure && make && make install && cd ../ && \
cd pinentry-1.0.0 && ./configure --enable-pinentry-curses --disable-pinentry-qt4 && make && make install && cd ../ && \
cd gpgme-1.9.0 && ./configure && make && make install && cd ../ && \
cd gnupg-2.1.21 && ./configure && make && make install && \
 
echo "/usr/local/lib" > /etc/ld.so.conf.d/gpg2.conf && ldconfig -v && \
 
cd $CD
 
echo "Complete !!!"
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
[SOLVED] standard for usage statement syntax hydraMax Programming 2 12-25-2011 07:34 PM
Looking for a standard way to measure CPU usage. ufmale Programming 4 03-19-2008 08:41 AM
src2pkg and non-standard configure BCarey Slackware 4 09-19-2007 10:06 PM
standard configure and Mandrake 10.1 CE FireHawk321 Linux - Software 3 11-24-2004 04:18 PM
How do I configure my standard Session-type erik_wout_ew2 Linux - Software 4 12-09-2003 11:02 AM

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

All times are GMT -5. The time now is 04:10 AM.

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