DESTDIR – Build to a different location

April 28, 2011 at 6:15 pm Leave a comment

The DESTDIR environment variable is a convention used in most makefiles. It is *very* useful when building binaries for installation.

The problem one comes across when building binaries is that variable set in configuration are used both as locations for installing, and locations used by the running process. So if you want to build binaries, install them somewhere, and then copy them somewhere else you have a problem.

The DESTDIR variable can get round this by overriding where binaries should be installed.

Common usecase

./configure
make
DESTDIR=../build/ make install;
Advertisements

Entry filed under: Uncategorized.

A rough outline of how X works Command line twitter

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Trackback this post  |  Subscribe to the comments via RSS Feed


April 2011
M T W T F S S
« Mar   May »
 123
45678910
11121314151617
18192021222324
252627282930  

%d bloggers like this: