Skip to content
Snippets Groups Projects
Commit 313dfe45 authored by jdh8d's avatar jdh8d
Browse files

No commit message

No commit message
parent c95b1b3f
Branches consecutive_fix
No related tags found
No related merge requests found
* text=auto !eol
/LICENSE.txt -text
/Makefile.in -text
/SConscript -text
/SConstruct -text
/config.guess -text
/config.sub -text
/configure -text
......@@ -15,6 +17,8 @@ include/zipr_opts.h -text
include/zipr_stats.h -text
/install-sh -text
src/Makefile.in -text
src/SConscript -text
src/SConstruct -text
src/main.cpp -text
src/memory_space.cpp -text
src/plugin_man.cpp -text
......
import shutil
import os
import tarfile
Import('env')
# build security transforms
irdbenv=env.Clone();
sectrans_path=os.environ['SECURITY_TRANSFORMS_HOME']
sectrans_sconscript=os.path.join(sectrans_path,"SConscript");
env=irdbenv.Clone()
Export('env') # for security_transforms.
SConscript(sectrans_sconscript, variant_dir='scons_build/irdb_libs')
#print 'env='
#print env.Dump()
SConscript("src/SConscript", variant_dir='scons_build/zipr')
import os
import sys
env=Environment()
# default build options
env.Replace(CFLAGS="-fPIC -fPIE ")
env.Replace(CXXFLAGS="-fPIC -fPIE ")
env.Replace(LINKFLAGS="-fPIC -fPIE ")
# parse arguments
env.Replace(SECURITY_TRANSFORMS_HOME=os.environ['SECURITY_TRANSFORMS_HOME'])
env.Replace(ZIPR_HOME=os.environ['ZIPR_HOME'])
env.Replace(ZIPR_INSTALL=os.environ['ZIPR_INSTALL'])
env.Replace(ZIPR_SDK=os.environ['ZIPR_SDK'])
env.Replace(debug=ARGUMENTS.get("debug",0))
env.Replace(do_64bit_build=ARGUMENTS.get("do_64bit_build",0))
if int(env['debug']) == 1:
print "Setting debug mode"
env.Append(CFLAGS=" -g")
env.Append(CXXFLAGS=" -g")
env.Append(LINKFLAGS=" -g")
else:
print "Setting release mode"
env.Append(CFLAGS=" -O3")
env.Append(CXXFLAGS=" -O3")
env.Append(LINKFLAGS=" -O3")
# set 32/64 bit build properly
#print "env[64bit]="+str(env['do_64bit_build'])
#if env['do_64bit_build'] is None:
# print 'Defaulting to default compilation size.'
#elif int(env['do_64bit_build']) == 1:
# print 'Using 64-bit compilation size.'
# env.Append(CFLAGS=" -m64")
# env.Append(CXXFLAGS=" -m64")
# env.Append(LINKFLAGS=" -m64")
# env.Append(SHLINKFLAGS=" -m64")
#else:
# print 'Using 32-bit compilation size.'
# env.Append(CFLAGS=" -m32")
# env.Append(CXXFLAGS=" -m32")
# env.Append(LINKFLAGS=" -m32")
# env.Append(SHLINKFLAGS=" -m32")
env['build_appfw']=0
env['build_tools']=0
Export('env')
SConscript("SConscript", variant_dir='build')
import os
Import('env')
myenv=env
myenv.Replace(SECURITY_TRANSFORMS_HOME=os.environ['SECURITY_TRANSFORMS_HOME'])
myenv.Replace(ZIPR_HOME=os.environ['ZIPR_HOME'])
myenv.Replace(ZIPR_SDK=os.environ['ZIPR_SDK'])
myenv.Replace(ZIPR_INSTALL=os.environ['ZIPR_INSTALL'])
files= '''
main.cpp
memory_space.cpp
plugin_man.cpp
zipr.cpp
zipr_options.cpp
zipr_stats.cpp
'''
# ELFIO needs to be first so we get the zipr version instead of the sectrans version. the zipr version is modified to include get_offset.
cpppath='''
.
$ZIPR_HOME/third_party/ELFIO/elfio-2.2
$SECURITY_TRANSFORMS_HOME/include/
$SECURITY_TRANSFORMS_HOME/libIRDB/include/
$SECURITY_TRANSFORMS_HOME/beaengine/include
$SECURITY_TRANSFORMS_HOME/beaengine/beaengineSources/Includes/
$ZIPR_HOME/include/
$ZIPR_SDK/include/
'''
libs='''
xform
IRDB-core
IRDB-cfg
BeaEngine_s_d
pqxx
transform
rewrite
pq
dl
EXEIO
'''
libpath='''
$SECURITY_TRANSFORMS_HOME/lib
'''
myenv.Append(CCFLAGS=" -Wall ")
myenv.Append(LDFLAGS=" -Wl,-E ") # export all symbols
myenv=myenv.Clone(CPPPATH=Split(cpppath), LIBS=Split(libs), LIBPATH=Split(libpath))
ziprexe=myenv.Program("zipr.exe", Split(files))
install=myenv.Install("$ZIPR_INSTALL/bin/", ziprexe)
Default(install)
env=Environment()
Export('env')
SConscript("SConscript")
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment