root/trunk/build/buildfonts.php

Revision 707, 1.6 kB (checked in by laurentj, 1 year ago)

renamed lib/fonts to lib/pdf-fonts

Line 
1 <?php
2 /**
3 * @package     jelix
4 * @author      Jouanneau Laurent
5 * @contributor
6 * @copyright   2007 Jouanneau laurent
7 * @link        http://www.jelix.org
8 * @licence     GNU General Public Licence see LICENCE file or http://www.gnu.org/licenses/gpl.html
9 */
10 $BUILD_OPTIONS = array(
11 'MAIN_TARGET_PATH'=> array(
12     "main directory where sources will be copied"// signification (false = option cachée)
13     '_dist',                                        // valeur par défaut (boolean = option booleene)
14     '',                                             // regexp pour la valeur ou vide=tout (seulement pour option non booleene)
15     ),
16 'PACKAGE_TAR_GZ'=>array(
17     "create a tar.gz package",
18     false,
19     ),
20 'PACKAGE_ZIP'=>array(
21     "create a zip package",
22     false,
23     ),
24 );
25 include(dirname(__FILE__).'/lib/jBuild.inc.php');
26
27 //----------------- Preparation des variables d'environnement
28
29 if($PACKAGE_TAR_GZ || $PACKAGE_ZIP ){
30     $PACKAGE_NAME='jelix-pdf-fonts';
31
32     $BUILD_TARGET_PATH = jBuildUtils::normalizeDir($MAIN_TARGET_PATH).$PACKAGE_NAME.'/';
33 }else{
34     $BUILD_TARGET_PATH = jBuildUtils::normalizeDir($MAIN_TARGET_PATH);
35 }
36
37
38 //----------------- Génération des sources
39
40 //... creation des repertoires
41 jBuildUtils::createDir($BUILD_TARGET_PATH);
42
43 //... execution des manifests
44 jManifest::process('build/manifests/fonts.mn', '.', $BUILD_TARGET_PATH, ENV::getAll());
45
46 //... packages
47
48 if($PACKAGE_TAR_GZ){
49     exec('tar czf '.$MAIN_TARGET_PATH.'/'.$PACKAGE_NAME.'.tar.gz -C '.$MAIN_TARGET_PATH.' '.$PACKAGE_NAME);
50 }
51
52 if($PACKAGE_ZIP){
53     chdir($MAIN_TARGET_PATH);
54     exec('zip -r '.$PACKAGE_NAME.'.zip '.$PACKAGE_NAME);
55     chdir(dirname(__FILE__));
56 }
57
58 exit(0);
59 ?>
Note: See TracBrowser for help on using the browser.
Download in other formats: Plain Text Original Format