From 33ce20f05ba8864711fc58717be1898d139dd1d9 Mon Sep 17 00:00:00 2001
From: Tim Mayberry <mojofunk@gmail.com>
Date: Sat, 26 Apr 2008 16:53:36 +1000
Subject: [PATCH] Add LIBDIR scons option for manually specifying the library directory name

---
 SConstruct |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/SConstruct b/SConstruct
index 6c04ffb..87dcaf2 100644
--- a/SConstruct
+++ b/SConstruct
@@ -31,6 +31,7 @@ subst_dict = { }
 opts = Options('scache.conf')
 opts.AddOptions(
     ('ARCH', 'Set architecture-specific compilation flags by hand (all flags as 1 argument)',''),
+    ('LIBDIR', 'Set the name of the directory to be used when installing libraries',''),
     ('WINDOWS_KEY', 'Set X Modifier (Mod1,Mod2,Mod3,Mod4,Mod5) for "Windows" key', 'Mod4'),
     BoolOption('AUDIOUNITS', 'Compile with Apple\'s AudioUnit library. (experimental)', 0),
     BoolOption('COREAUDIO', 'Compile with Apple\'s CoreAudio library', 0),
@@ -715,11 +716,11 @@ if env['FPU_OPTIMIZATION']:
 # end optimization section
 
 # handle x86/x86_64 libdir properly
-
-if env['DIST_TARGET'] == 'x86_64':
-    env['LIBDIR']='lib64'
-else:
-    env['LIBDIR']='lib'
+if not env['LIBDIR']:
+        if env['DIST_TARGET'] == 'x86_64':
+                env['LIBDIR']='lib64'
+        else:
+                env['LIBDIR']='lib'
 
 #
 # a single way to test if we're on OS X
-- 
1.5.4.1

