Browse Source

attempted fix for bison dependencies. maybe broken still.

David Rose 23 years ago
parent
commit
564c893286
3 changed files with 15 additions and 12 deletions
  1. 5 4
      dtool/pptempl/Template.gmsvc.pp
  2. 5 4
      dtool/pptempl/Template.msvc.pp
  3. 5 4
      dtool/pptempl/Template.unix.pp

+ 5 - 4
dtool/pptempl/Template.gmsvc.pp

@@ -750,6 +750,7 @@ $[target] : $[source]
 $[TAB] $[BISON] $[YFLAGS] -y $[if $[YACC_PREFIX],-d --name-prefix=$[YACC_PREFIX]] $[source]
 $[TAB] mv y.tab.c $[target]
 $[TAB] mv y.tab.h $[patsubst %.yxx,%.h,$[source]]
+$[target_header] : $[target]
 $[target].prebuilt : $[target]
 $[TAB] cp $[target] $[target].prebuilt
 $[target_header].prebuilt : $[target_header]
@@ -817,7 +818,7 @@ $[TAB] $[COMPILE_C]
 
 // Yacc must run before some files can be compiled, so all files
 // depend on yacc having run.
-$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.cxx] $[so_dir]/stamp
+$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.h] $[so_dir]/stamp
 $[TAB] $[COMPILE_C++]
 
 #end file
@@ -849,7 +850,7 @@ $[TAB] $[COMPILE_C++]
 #define COMPILE_LINE $[COMPILE_C++]
 #endif
 
-$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.cxx] $[target_pch] $[st_dir]/stamp
+$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.h] $[target_pch] $[st_dir]/stamp
 $[TAB] $[COMPILE_LINE]
 
 #end file
@@ -886,7 +887,7 @@ $[target_pch] : $[target_obj]
 #define flags $[noopt_c++flags] $[CFLAGS_SHARED] $[all_sources $[building_var:%=/D%],$[file]]
 // Yacc must run before some files can be compiled, so all files
 // depend on yacc having run.
-$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.cxx] $[so_dir]/stamp
+$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.h] $[so_dir]/stamp
 $[TAB] $[COMPILE_C++]
 
 #end file
@@ -898,7 +899,7 @@ $[TAB] $[COMPILE_C++]
 #define source $[patsubst %.lxx %.yxx,%.cxx,$[file]]
 #define ipath $[file_ipath]
 #define flags $[noopt_c++flags] $[all_sources $[building_var:%=/D%],$[file]]
-$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.cxx] $[st_dir]/stamp
+$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.h] $[st_dir]/stamp
 $[TAB] $[COMPILE_C++]
 
 #end file

+ 5 - 4
dtool/pptempl/Template.msvc.pp

@@ -724,6 +724,7 @@ $[target] : $[source]
 $[TAB] $[BISON] $[YFLAGS] -y $[if $[YACC_PREFIX],-d --name-prefix=$[YACC_PREFIX]] $[source]
 $[TAB] move y.tab.c $[target]
 $[TAB] move y.tab.h $[patsubst %.yxx,%.h,$[source]]
+$[target_header] : $[target]
 $[target].prebuilt : $[target]
 $[TAB] copy $[target] $[target].prebuilt
 $[target_header].prebuilt : $[target_header]
@@ -809,7 +810,7 @@ $[TAB] $[COMPILE_C]
 
 // Yacc must run before some files can be compiled, so all files
 // depend on yacc having run.
-$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.cxx] $[target_pch]
+$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.h] $[target_pch]
 $[TAB] $[COMPILE_LINE]
 
 #end file
@@ -842,7 +843,7 @@ $[TAB] $[COMPILE_LINE]
 
 // Yacc must run before some files can be compiled, so all files
 // depend on yacc having run.
-$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.cxx] $[target_pch]
+$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.h] $[target_pch]
 $[TAB] $[COMPILE_LINE]
 
 #end file
@@ -878,7 +879,7 @@ $[target_pch] : $[target_obj]
 #define flags $[noopt_c++flags] $[CFLAGS_SHARED] $[all_sources $[building_var:%=/D%],$[file]]
 // Yacc must run before some files can be compiled, so all files
 // depend on yacc having run.
-$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.cxx]
+$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.h]
 $[TAB] $[COMPILE_C++]
 
 #end file
@@ -890,7 +891,7 @@ $[TAB] $[COMPILE_C++]
 #define source $[patsubst %.lxx %.yxx,%.cxx,$[file]]
 #define ipath $[file_ipath]
 #define flags $[noopt_c++flags] $[all_sources $[building_var:%=/D%],$[file]]
-$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.cxx]
+$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.h]
 $[TAB] $[COMPILE_C++]
 
 #end file

+ 5 - 4
dtool/pptempl/Template.unix.pp

@@ -599,6 +599,7 @@ $[target] : $[source]
 $[TAB]$[BISON] -y $[YFLAGS] $[if $[YACC_PREFIX],-d --name-prefix=$[YACC_PREFIX]] $[source]
 $[TAB]mv y.tab.c $[target]
 $[TAB]mv y.tab.h $[target_header]
+$[target_header] : $[target]
 $[target].prebuilt : $[target]
 $[TAB]cp $[target] $[target].prebuilt
 $[target_header].prebuilt : $[target_header]
@@ -666,7 +667,7 @@ $[TAB]$[COMPILE_C]
 #define flags $[c++flags] $[CFLAGS_SHARED]
 // Yacc must run before some files can be compiled, so all files
 // depend on yacc having run.
-$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.cxx]
+$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.h]
 $[TAB]$[COMPILE_C++]
 
 #end file
@@ -678,7 +679,7 @@ $[TAB]$[COMPILE_C++]
 #define source $[file]
 #define ipath $[file_ipath]
 #define flags $[c++flags]
-$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.cxx]
+$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.h]
 $[TAB]$[COMPILE_C++]
 
 #end file
@@ -691,7 +692,7 @@ $[TAB]$[COMPILE_C++]
 #define flags $[noopt_c++flags] $[CFLAGS_SHARED]
 // Yacc must run before some files can be compiled, so all files
 // depend on yacc having run.
-$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.cxx]
+$[target] : $[source] $[dependencies $[file]] $[yxx_so_sources:%.yxx=%.h]
 $[TAB]$[COMPILE_C++]
 
 #end file
@@ -703,7 +704,7 @@ $[TAB]$[COMPILE_C++]
 #define source $[patsubst %.lxx %.yxx,%.cxx,$[file]]
 #define ipath $[file_ipath]
 #define flags $[noopt_c++flags]
-$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.cxx]
+$[target] : $[source] $[dependencies $[file]] $[yxx_st_sources:%.yxx=%.h]
 $[TAB]$[COMPILE_C++]
 
 #end file