You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
83 lines
2.5 KiB
83 lines
2.5 KiB
#!/usr/bin/python
|
|
# kio-locate
|
|
#
|
|
# Copyright (C) 2005 by Tobi Vollebregt
|
|
# tobivollebregt@gmail.com
|
|
#
|
|
# Thanks to Google's Summer Of Code Program!
|
|
#
|
|
# Copyright (C) 2005 by Armin Straub
|
|
# linux@arminstraub.de
|
|
#
|
|
# Adapted from the example shipping with bksys.
|
|
# Thomas Nagy, 2004, 2005
|
|
# Thanks for this great tool!
|
|
|
|
"""
|
|
help -> scons -h
|
|
compile -> scons
|
|
clean -> scons -c
|
|
install -> scons install
|
|
uninstall -> scons -c install
|
|
configure -> scons configure prefix=/tmp/ita debug=full extraincludes=/usr/local/include:/tmp/include prefix=/usr/local
|
|
|
|
Run from a subdirectory -> scons -u
|
|
The variables are saved automatically after the first run (look at cache/kde.cache.py, ..)
|
|
"""
|
|
|
|
###################################################################
|
|
# LOAD THE ENVIRONMENT AND SET UP THE TOOLS
|
|
###################################################################
|
|
|
|
## Load the builders in config
|
|
env = Environment( tools=['default', 'generic', 'kde'], toolpath=['./admin'])
|
|
|
|
# Set the build directory so we can do "rm -rf build" to clean up.
|
|
BuildDir('build/src', 'src')
|
|
|
|
env.KDEuse("environ")
|
|
#env.KDEuse("environ rpath lang_qt thread nohelp")
|
|
|
|
# Add -DHAVE_UDS_HIDDEN if we detected the UDS_HIDDEN patch.
|
|
if '1' in env['HAVE_UDS_HIDDEN']:
|
|
env.Append(CPPFLAGS = ['-DHAVE_UDS_HIDDEN'])
|
|
|
|
###################################################################
|
|
# SCRIPTS FOR BUILDING THE TARGETS
|
|
###################################################################
|
|
|
|
## target processing is done in the subdirectories
|
|
env.subdirs('build/src')
|
|
|
|
############################
|
|
## Process the documentation
|
|
############################
|
|
|
|
## Use a distinct environment
|
|
myenv=env.Copy()
|
|
|
|
## Define this to enable docbook file dependency tracking
|
|
#myenv['i_am_a_documentation_writer']=1
|
|
|
|
# This shouldn't be needed, but it works around a (possible) bug in bksys 1.5.2.rc1.
|
|
# myenv['_BUILDDIR_']='build'
|
|
|
|
## Use docfolder for each documentation directory
|
|
## The parameters of docfolder are: documentation dir, language code, app name
|
|
myenv.docfolder('doc/en/', 'en', 'kio-locate/')
|
|
#myenv.docfolder('doc/fr/', 'fr', 'kio-locate/')
|
|
|
|
############################
|
|
## Process the translations
|
|
############################
|
|
|
|
## They are usually located in the po/ directory
|
|
## We use myenv here because it has the _BUILDDIR_ workaround. See above.
|
|
myenv.KDElang('po/', 'kio-locate')
|
|
|
|
###################################################################
|
|
# CONVENIENCE FUNCTIONS TO EMULATE 'make dist' and 'make distclean'
|
|
###################################################################
|
|
|
|
env.dist('kio-locate')
|