ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi everyone.
I've built side version of glibc with host target and compiler options of my choice. I wonder whether I should "make install" it to some folder of mine. Is it dangerous? I'm not going to replace system's standard glibc (and most probably don't have permissions to do it anyway).
So what exactly are the consequences of "make install" other than screwing some enviroment variables in my current shell?
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150
Rep:
Most standard make files allow you to 'stage' an install with the DESTDIR variable so
Code:
make install DESTDIR=/tmp/xxx
Would place all the installed files/folders under /tmp/xxx, so /tmp//xxx/lib, /tmp/xxx/usr/lib etc etc, this can be a good way to check what is going wher, most package managers use this system to create an archive before installing it to the real system.
Glibc on it's own is of very little use as it is the main set of library's that a linux system depends on, things like printf, strdup etc, if you try to manualluy replace your system glibc with a new one unless you know what you are doing you are in for a world of hurt!
Thanks Keith. I've already used --prefix=/path/to/my/folder option when configuring glibc, so I guess this is the location that "make install" will use. Or I can call "make install install_root=/path/to/my/folder" to be absolutely sure.
Let me repeat my concern: installing glibc to my local folder - is it safe? Does it affect my environment outside current shell ?
Just to keep things somewhat clearer, note that "make" is just a program that processes the make script file, typically "Makefile."
See info make for details, but just look at the install: section of your makefile to see exactly what make with a target of install will attempt to do.
Hi everyone.
I've built side version of glibc with host target and compiler options of my choice. I wonder whether I should "make install" it to some folder of mine. Is it dangerous? I'm not going to replace system's standard glibc (and most probably don't have permissions to do it anyway).
So what exactly are the consequences of "make install" other than screwing some enviroment variables in my current shell?
Thanks.
"make install" does what the steps show in the Makefile under/after the tag or phrase install:
Typically this copies your binaries to the desired locations, all depending if you chose defaults or set options for target directories. It also typically establishes any symbolic links which it requires. But overall, it really depends what the creator/author of the software has chosen to do when you invoke the install argument.
Therefore when I have concerns or questions, I view the Makefile and see what actions I can expect if I invoke install.
Thanks everyone.
I was worried that "make install" can also mess with my env. variables, like LD_LIBRARY_PATH or something like this. But it doesn't look so, looks like all "make install" does is populate folder of my choice with files. Unless I'm installing to default system's path /usr/... , I should be safe.
Marking thread as solved.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.