3838 )
3939);
4040
41- $ compatible ->license = $ package ->license ;
4241
4342$ package ->files ['tests/bootstrap.php ' ] = array_merge_recursive (
4443 $ package ->files ['tests/bootstrap.php ' ]->getArrayCopy (), $ srcDirTask
6362 )
6463);
6564
66- //$compatible->files[
67- // "test/{$package->channel}/{$package->name}/bootstrap.php"
68- // ] = array_merge_recursive(
69- // $compatible->files[
70- // "test/{$package->channel}/{$package->name}/bootstrap.php"
71- // ]->getArrayCopy(), $srcDirTask
72- //);
73- //
74- //$compatible->files["doc/{$package->channel}/{$package->name}/phpdoc.dist.xml"]
75- // = array_merge_recursive(
76- // $compatible->files[
77- // "doc/{$package->channel}/{$package->name}/phpdoc.dist.xml"
78- // ]->getArrayCopy(), $srcDirTask
79- //);
80- //
81- //$compatible->files["doc/{$package->channel}/{$package->name}/doxygen.ini"]
82- // = array_merge_recursive(
83- // $compatible->files[
84- // "doc/{$package->channel}/{$package->name}/doxygen.ini"
85- // ]->getArrayCopy(), $srcDirTask,
86- // array(
87- // 'tasks:replace' => array(
88- // array(
89- // 'attribs' => array(
90- // 'from' => 'GIT: $Id$',
91- // 'to' => 'version',
92- // 'type' => 'package-info'
93- // )
94- // )
95- // )
96- // )
97- //);
65+ $ hasCompatible = isset ($ compatible );
66+ if ($ hasCompatible ) {
67+ $ compatible ->license = $ package ->license ;
68+ $ compatible ->files [
69+ "test/ {$ package ->channel }/ {$ package ->name }/bootstrap.php "
70+ ] = array_merge_recursive (
71+ $ compatible ->files [
72+ "test/ {$ package ->channel }/ {$ package ->name }/bootstrap.php "
73+ ]->getArrayCopy (), $ srcDirTask
74+ );
75+
76+ $ compatible ->files [
77+ "doc/ {$ package ->channel }/ {$ package ->name }/phpdoc.dist.xml "
78+ ] = array_merge_recursive (
79+ $ compatible ->files [
80+ "doc/ {$ package ->channel }/ {$ package ->name }/phpdoc.dist.xml "
81+ ]->getArrayCopy (), $ srcDirTask
82+ );
83+
84+ $ compatible ->files ["doc/ {$ package ->channel }/ {$ package ->name }/doxygen.ini " ]
85+ = array_merge_recursive (
86+ $ compatible ->files [
87+ "doc/ {$ package ->channel }/ {$ package ->name }/doxygen.ini "
88+ ]->getArrayCopy (), $ srcDirTask ,
89+ array (
90+ 'tasks:replace ' => array (
91+ array (
92+ 'attribs ' => array (
93+ 'from ' => 'GIT: $Id$ ' ,
94+ 'to ' => 'version ' ,
95+ 'type ' => 'package-info '
96+ )
97+ )
98+ )
99+ )
100+ );
101+ }
98102
99103$ oldCwd = getcwd ();
100104chdir (__DIR__ );
112116 $ package ->files [$ filename ]->getArrayCopy (), $ srcFileTasks
113117 );
114118
115- $ compatibleFilename = str_replace ('src/ ' , 'php/ ' , $ filename );
116- $ compatible ->files [$ compatibleFilename ] = array_merge_recursive (
117- $ compatible ->files [$ compatibleFilename ]->getArrayCopy (),
118- $ srcFileTasks
119- );
119+ if ($ hasCompatible ) {
120+ $ compatibleFilename = str_replace ('src/ ' , 'php/ ' , $ filename );
121+ $ compatible ->files [$ compatibleFilename ] = array_merge_recursive (
122+ $ compatible ->files [$ compatibleFilename ]->getArrayCopy (),
123+ $ srcFileTasks
124+ );
125+ }
120126}
121127chdir ($ oldCwd );
0 commit comments