Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=fwsetup-ng.git;a=commitdiff;h=5acdfedbeaf811427a7454afa9c63cd19131f72d

commit 5acdfedbeaf811427a7454afa9c63cd19131f72d
Author: James Buren <[email protected]>
Date:   Mon Aug 27 00:37:13 2012 -0500

import scons file

diff --git a/SConstruct b/SConstruct
new file mode 100644
index 0000000..08a6a6e
--- /dev/null
+++ b/SConstruct
@@ -0,0 +1,46 @@
+import os
+
+env = Environment()
+
+def CheckPkg(context,pkg):
+  context.Message('Checking for %s... ' % pkg)
+  rv = context.TryAction('pkg-config --exists \'%s\'' % pkg)[0]
+  context.Result(rv)
+  return rv
+
+conf = Configure(env,{ "CheckPkg" : CheckPkg })
+
+if not conf.CheckPkg('uuid'):
+  print 'libuuid was not found.'
+  Exit(1)
+
+if not conf.CheckPkg('blkid'):
+  print 'libblkid was not found.'
+  Exit(1)
+
+if not conf.CheckPkg('libnewt'):
+  print 'libnewt was not found.'
+  Exit(1)
+
+conf.Finish()
+
+try:
+  cxxflags = os.environ['CXXFLAGS']
+except KeyError:
+  cxxflags = '-O2'
+  pass
+
+env.Append(CXXFLAGS = cxxflags)
+
+env.Append(CXXFLAGS = '-Wall -Wextra -Wno-unused-parameter -ggdb3 -DNEWT')
+
+env.ParseConfig('pkg-config --cflags --libs uuid blkid libnewt')
+
+env.Program('fwsetup',[
+  'Main.cc',
+  'GptPartitionTable.cc',
+  'DosPartitionTable.cc',
+  'Device.cc',
+  'UserInterface.cc',
+  'Utility.cc'
+])
\ No newline at end of file
_______________________________________________
Frugalware-git mailing list
[email protected]
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to