summaryrefslogtreecommitdiff
path: root/Jamfile.jam
diff options
context:
space:
mode:
authorarseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640>2010-07-19 09:57:32 +0000
committerarseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640>2010-07-19 09:57:32 +0000
commit7d24b9b5655d584b6dc8b89df7cbd58d2e940a81 (patch)
tree0301baa043cd688068f6ffa11ad56d284031e664 /Jamfile.jam
parent86ac39edb09647b83784c078f9ea3bd3b7a7d4e8 (diff)
Set svn:eol-style to native for all text files
git-svn-id: http://pugixml.googlecode.com/svn/trunk@607 99668b35-9821-0410-8761-19e4c4f06640
Diffstat (limited to 'Jamfile.jam')
-rw-r--r--Jamfile.jam318
1 files changed, 159 insertions, 159 deletions
diff --git a/Jamfile.jam b/Jamfile.jam
index ae986cc..63dd298 100644
--- a/Jamfile.jam
+++ b/Jamfile.jam
@@ -1,159 +1,159 @@
-# Latest jamplus is needed to use this
-
-# Targets:
-# pugixml - build pugixml library
-# tests - build pugixml test suite
-# run_tests - run pugixml test suite
-# coverage - get test suite coverage
-
-# Options:
-# toolset=name - select toolset
-# supported toolsets: mingw*, msvc*
-
-# default toolset/configuration
-if ( ! $(toolset) )
-{
- if ( $(OS) = SOLARIS )
- {
- toolset = suncc ;
- }
- else if ( $(UNIX) )
- {
- local GCCVERSION = [ Subst [ Shell "gcc -dumpversion" ] : $(NEWLINE) ] ;
- toolset = "gcc"$(GCCVERSION) ;
- }
- else
- {
- toolset = msvc ;
- }
-}
-
-if ( ! $(configuration) )
-{
- configuration = "debug" ;
-}
-
-if ( ! $(defines) )
-{
- defines = "PUGIXML_STANDARD" ;
-}
-
-# coverage options
-if ( $(toolset:I=^mingw) || $(toolset:I=^gcc) )
-{
- CCFLAGS = -fprofile-arcs -ftest-coverage ;
- LDFLAGS = -fprofile-arcs ;
- GCOVFLAGS = -n ;
-}
-
-# build folder
-BUILD = build ;
-
-# enable dependency cache
-DEPCACHE.standard = $(BUILD)/.depcache ;
-
-# rules
-include "Jamrules.jam" ;
-
-# split define sets into list
-local DEFINESETS = [ Split $(defines) : ':' ] ;
-
-# split configurations into list
-local CONFIGURATIONS = [ Split $(configuration) : ',' ] ;
-
-for CONFIG in $(CONFIGURATIONS)
-{
- for DEFINESET in $(DEFINESETS)
- {
- local DEFINES = [ Split $(DEFINESET) : ',' ] ;
-
- # build folder
- local CFGBUILD = $(BUILD)/$(toolset)/$(DEFINES:J=_)/$(CONFIG) ;
-
- # compilation options
- local CFGFLAGS = $(CCFLAGS) [ GetCFlags $(CONFIG) : $(DEFINES) ] ;
-
- # build library
- local PUGIXML = $(CFGBUILD)/pugixml.lib ;
- Library $(PUGIXML) : src/pugixml.cpp src/pugixpath.cpp : $(CFGFLAGS) ;
- Alias pugixml : $(PUGIXML) ;
-
- # build tests
- local TESTS = $(CFGBUILD)/tests.exe ;
- Application $(TESTS) : [ Glob tests : *.cpp ] : $(CFGFLAGS) : $(PUGIXML) ;
- Alias tests : $(TESTS) ;
-
- # run tests
- Test $(TESTS)_run : $(TESTS) ;
- Alias run_tests : $(TESTS)_run ;
-
- # gather coverage
- Coverage $(TESTS)_coverage : $(PUGIXML) ;
- Alias coverage : $(TESTS)_coverage ;
-
- GCOVFLAGS on $(TESTS)_coverage = $(GCOVFLAGS) -o $(CFGBUILD)/src ; # because stupid gcov can't find files via relative paths
-
- # add special autotest markers to build log
- if $(autotest)
- {
- COVPREFIX on $(TESTS)_coverage = "... autotest $(CONFIG) [$(DEFINESET)]" ;
- }
-
- # gather coverage after tests run
- Depends $(TESTS)_coverage : $(TESTS)_run ;
- }
-}
-
-# documentation
-Documentation docs/manual.html : docs/manual.qbk : docs/manual.xsl ;
-Documentation docs/quickstart.html : docs/quickstart.qbk : docs/quickstart.xsl ;
-
-Alias docs : docs/manual.html docs/quickstart.html ;
-
-# samples
-for SAMPLE in [ Glob docs/samples : *.cpp ]
-{
- local CONFIG = "debug" ;
- local DEFINES = "PUGIXML_STANDARD" ;
-
- # build folder
- local CFGBUILD = $(BUILD)/$(toolset)/$(DEFINES:J=_)/$(CONFIG) ;
-
- # compilation options
- local CFGFLAGS = $(CCFLAGS) [ GetCFlags $(CONFIG) : $(DEFINES) ] ;
- CFGFLAGS += -I src ;
-
- # build and run sample
- local EXECUTABLE = $(CFGBUILD)/samples/$(SAMPLE:S=.exe) ;
- local PUGIXML = $(CFGBUILD)/pugixml.lib ;
-
- Application $(EXECUTABLE) : $(SAMPLE) : $(CFGFLAGS) : $(PUGIXML) ;
-
- RunSampleAction $(EXECUTABLE)_run : $(EXECUTABLE) ;
- Depends $(EXECUTABLE)_run : $(EXECUTABLE) ;
-
- Depends samples : $(EXECUTABLE)_run ;
-}
-
-# release
-VERSION = 0.9 ;
-RELEASE_FILES =
- [ Glob contrib : *.cpp *.hpp ]
- [ Glob src : *.cpp *.hpp ]
- [ Glob docs : *.html *.css ]
- [ Glob docs/samples : *.cpp *.hpp *.xml ]
- [ Glob docs/images : *.png ]
- [ Glob docs/manual : *.html ]
- @("scripts/**":W=:X=svn)
- readme.txt
- ;
-
-actions ArchiveAction
-{
- perl tests/archive.pl $(<) $(>)
-}
-
-ArchiveAction pugixml-$(VERSION).zip : $(RELEASE_FILES) ;
-ArchiveAction pugixml-$(VERSION).tar.gz : $(RELEASE_FILES) ;
-Depends release : pugixml-$(VERSION).zip pugixml-$(VERSION).tar.gz : $(RELEASE_FILES) ;
-NotFile release ;
+# Latest jamplus is needed to use this
+
+# Targets:
+# pugixml - build pugixml library
+# tests - build pugixml test suite
+# run_tests - run pugixml test suite
+# coverage - get test suite coverage
+
+# Options:
+# toolset=name - select toolset
+# supported toolsets: mingw*, msvc*
+
+# default toolset/configuration
+if ( ! $(toolset) )
+{
+ if ( $(OS) = SOLARIS )
+ {
+ toolset = suncc ;
+ }
+ else if ( $(UNIX) )
+ {
+ local GCCVERSION = [ Subst [ Shell "gcc -dumpversion" ] : $(NEWLINE) ] ;
+ toolset = "gcc"$(GCCVERSION) ;
+ }
+ else
+ {
+ toolset = msvc ;
+ }
+}
+
+if ( ! $(configuration) )
+{
+ configuration = "debug" ;
+}
+
+if ( ! $(defines) )
+{
+ defines = "PUGIXML_STANDARD" ;
+}
+
+# coverage options
+if ( $(toolset:I=^mingw) || $(toolset:I=^gcc) )
+{
+ CCFLAGS = -fprofile-arcs -ftest-coverage ;
+ LDFLAGS = -fprofile-arcs ;
+ GCOVFLAGS = -n ;
+}
+
+# build folder
+BUILD = build ;
+
+# enable dependency cache
+DEPCACHE.standard = $(BUILD)/.depcache ;
+
+# rules
+include "Jamrules.jam" ;
+
+# split define sets into list
+local DEFINESETS = [ Split $(defines) : ':' ] ;
+
+# split configurations into list
+local CONFIGURATIONS = [ Split $(configuration) : ',' ] ;
+
+for CONFIG in $(CONFIGURATIONS)
+{
+ for DEFINESET in $(DEFINESETS)
+ {
+ local DEFINES = [ Split $(DEFINESET) : ',' ] ;
+
+ # build folder
+ local CFGBUILD = $(BUILD)/$(toolset)/$(DEFINES:J=_)/$(CONFIG) ;
+
+ # compilation options
+ local CFGFLAGS = $(CCFLAGS) [ GetCFlags $(CONFIG) : $(DEFINES) ] ;
+
+ # build library
+ local PUGIXML = $(CFGBUILD)/pugixml.lib ;
+ Library $(PUGIXML) : src/pugixml.cpp src/pugixpath.cpp : $(CFGFLAGS) ;
+ Alias pugixml : $(PUGIXML) ;
+
+ # build tests
+ local TESTS = $(CFGBUILD)/tests.exe ;
+ Application $(TESTS) : [ Glob tests : *.cpp ] : $(CFGFLAGS) : $(PUGIXML) ;
+ Alias tests : $(TESTS) ;
+
+ # run tests
+ Test $(TESTS)_run : $(TESTS) ;
+ Alias run_tests : $(TESTS)_run ;
+
+ # gather coverage
+ Coverage $(TESTS)_coverage : $(PUGIXML) ;
+ Alias coverage : $(TESTS)_coverage ;
+
+ GCOVFLAGS on $(TESTS)_coverage = $(GCOVFLAGS) -o $(CFGBUILD)/src ; # because stupid gcov can't find files via relative paths
+
+ # add special autotest markers to build log
+ if $(autotest)
+ {
+ COVPREFIX on $(TESTS)_coverage = "... autotest $(CONFIG) [$(DEFINESET)]" ;
+ }
+
+ # gather coverage after tests run
+ Depends $(TESTS)_coverage : $(TESTS)_run ;
+ }
+}
+
+# documentation
+Documentation docs/manual.html : docs/manual.qbk : docs/manual.xsl ;
+Documentation docs/quickstart.html : docs/quickstart.qbk : docs/quickstart.xsl ;
+
+Alias docs : docs/manual.html docs/quickstart.html ;
+
+# samples
+for SAMPLE in [ Glob docs/samples : *.cpp ]
+{
+ local CONFIG = "debug" ;
+ local DEFINES = "PUGIXML_STANDARD" ;
+
+ # build folder
+ local CFGBUILD = $(BUILD)/$(toolset)/$(DEFINES:J=_)/$(CONFIG) ;
+
+ # compilation options
+ local CFGFLAGS = $(CCFLAGS) [ GetCFlags $(CONFIG) : $(DEFINES) ] ;
+ CFGFLAGS += -I src ;
+
+ # build and run sample
+ local EXECUTABLE = $(CFGBUILD)/samples/$(SAMPLE:S=.exe) ;
+ local PUGIXML = $(CFGBUILD)/pugixml.lib ;
+
+ Application $(EXECUTABLE) : $(SAMPLE) : $(CFGFLAGS) : $(PUGIXML) ;
+
+ RunSampleAction $(EXECUTABLE)_run : $(EXECUTABLE) ;
+ Depends $(EXECUTABLE)_run : $(EXECUTABLE) ;
+
+ Depends samples : $(EXECUTABLE)_run ;
+}
+
+# release
+VERSION = 0.9 ;
+RELEASE_FILES =
+ [ Glob contrib : *.cpp *.hpp ]
+ [ Glob src : *.cpp *.hpp ]
+ [ Glob docs : *.html *.css ]
+ [ Glob docs/samples : *.cpp *.hpp *.xml ]
+ [ Glob docs/images : *.png ]
+ [ Glob docs/manual : *.html ]
+ @("scripts/**":W=:X=svn)
+ readme.txt
+ ;
+
+actions ArchiveAction
+{
+ perl tests/archive.pl $(<) $(>)
+}
+
+ArchiveAction pugixml-$(VERSION).zip : $(RELEASE_FILES) ;
+ArchiveAction pugixml-$(VERSION).tar.gz : $(RELEASE_FILES) ;
+Depends release : pugixml-$(VERSION).zip pugixml-$(VERSION).tar.gz : $(RELEASE_FILES) ;
+NotFile release ;