From f91e847562c22613de572030a4b7b029c70b45e8 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 6 Aug 2014 09:23:37 +0200 Subject: [PATCH] Qual: Removed had coded value for version. --- build/doxygen/dolibarr-doxygen-build.pl | 21 +++++++++++++++++++-- build/doxygen/dolibarr-doxygen.doxyfile | 2 +- build/doxygen/doxygen_header.html | 16 ++++++++-------- 3 files changed, 28 insertions(+), 11 deletions(-) diff --git a/build/doxygen/dolibarr-doxygen-build.pl b/build/doxygen/dolibarr-doxygen-build.pl index 65fc027ca32..f8c8c480081 100755 --- a/build/doxygen/dolibarr-doxygen-build.pl +++ b/build/doxygen/dolibarr-doxygen-build.pl @@ -30,8 +30,25 @@ if (! -s $CONFFILE) exit 1; } -print "Running doxygen, please wait...\n"; -$result=`doxygen $OPTIONS $CONFFILE 2>&1`; +$SOURCE="../.."; + +# Get version $MAJOR, $MINOR and $BUILD +$result = open( IN, "< " . $SOURCE . "/htdocs/filefunc.inc.php" ); +if ( !$result ) { die "Error: Can't open descriptor file " . $SOURCE . "/htdocs/filefunc.inc.php\n"; } +while () { + if ( $_ =~ /define\('DOL_VERSION','([\d\.a-z\-]+)'\)/ ) { $PROJVERSION = $1; break; } +} +close IN; +($MAJOR,$MINOR,$BUILD)=split(/\./,$PROJVERSION,3); +if ($MINOR eq '') { die "Error can't detect version into ".$SOURCE . "/htdocs/filefunc.inc.php"; } + + +$version=$MAJOR.".".$MINOR.".".$BUILD; + + +print "Running doxygen for version ".$version.", please wait...\n"; +print "cat $CONFFILE | sed -e 's/x\.y\.z/".$version."/' | doxygen $OPTIONS - 2>&1\n"; +$result=`cat $CONFFILE | sed -e 's/x\.y\.z/$version/' | doxygen $OPTIONS - 2>&1`; print $result; diff --git a/build/doxygen/dolibarr-doxygen.doxyfile b/build/doxygen/dolibarr-doxygen.doxyfile index 7a6bcb43119..912c72b4d69 100644 --- a/build/doxygen/dolibarr-doxygen.doxyfile +++ b/build/doxygen/dolibarr-doxygen.doxyfile @@ -31,7 +31,7 @@ PROJECT_NAME = dolibarr # This could be handy for archiving the generated documentation or # if some version control system is used. -PROJECT_NUMBER = 3.5 +PROJECT_NUMBER = x.y.z # The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) # base path where the generated documentation will be put. diff --git a/build/doxygen/doxygen_header.html b/build/doxygen/doxygen_header.html index 8d367cccb67..363d408d43c 100755 --- a/build/doxygen/doxygen_header.html +++ b/build/doxygen/doxygen_header.html @@ -35,15 +35,15 @@ File added into doxygen generated documentation
- + + + -