|
@@ -28,6 +28,16 @@
|
|
|
|
|
|
|
|
#define texattrib_file $[texattrib_dir]/textures.txa
|
|
#define texattrib_file $[texattrib_dir]/textures.txa
|
|
|
|
|
|
|
|
|
|
+#if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+ #define TOUCH_CMD echo.
|
|
|
|
|
+ #define COPY_CMD xcopy /I/Y
|
|
|
|
|
+ #define DEL_CMD del /f/s/q
|
|
|
|
|
+#else
|
|
|
|
|
+ #define TOUCH_CMD touch
|
|
|
|
|
+ #define COPY_CMD cp
|
|
|
|
|
+ #define DEL_CMD rm -rf
|
|
|
|
|
+#endif
|
|
|
|
|
+
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
//////////////////////////////////////////////////////////////////////
|
|
|
#if $[eq $[DIR_TYPE], models]
|
|
#if $[eq $[DIR_TYPE], models]
|
|
|
//////////////////////////////////////////////////////////////////////
|
|
//////////////////////////////////////////////////////////////////////
|
|
@@ -220,40 +230,52 @@ uninstall : uninstall-other uninstall-bam
|
|
|
|
|
|
|
|
clean-bam :
|
|
clean-bam :
|
|
|
#if $[bam_targets]
|
|
#if $[bam_targets]
|
|
|
-$[TAB]rm -rf $[bam_dir]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[bam_dir]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[bam_dir]
|
|
|
|
|
+ #endif
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
clean-pal : clean-bam
|
|
clean-pal : clean-bam
|
|
|
#if $[pal_egg_targets]
|
|
#if $[pal_egg_targets]
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[pal_egg_dir]]
|
|
|
|
|
+ #else
|
|
|
$[TAB]rm -rf $[pal_egg_dir]
|
|
$[TAB]rm -rf $[pal_egg_dir]
|
|
|
|
|
+ #endif
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
clean-flt :
|
|
clean-flt :
|
|
|
#if $[build_flt_eggs]
|
|
#if $[build_flt_eggs]
|
|
|
-$[TAB]rm -f $[build_flt_eggs]
|
|
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[build_flt_eggs]
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
clean-lwo :
|
|
clean-lwo :
|
|
|
#if $[build_lwo_eggs]
|
|
#if $[build_lwo_eggs]
|
|
|
-$[TAB]rm -f $[build_lwo_eggs]
|
|
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[build_lwo_eggs]
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
clean-maya :
|
|
clean-maya :
|
|
|
#if $[build_maya_eggs]
|
|
#if $[build_maya_eggs]
|
|
|
-$[TAB]rm -f $[build_maya_eggs]
|
|
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[build_maya_eggs]
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
clean-soft :
|
|
clean-soft :
|
|
|
#if $[build_soft_eggs]
|
|
#if $[build_soft_eggs]
|
|
|
-$[TAB]rm -f $[build_soft_eggs]
|
|
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[build_soft_eggs]
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
clean : clean-pal
|
|
clean : clean-pal
|
|
|
#if $[build_eggs]
|
|
#if $[build_eggs]
|
|
|
-$[TAB]rm -f $[build_eggs] *.pt
|
|
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[build_eggs] *.pt
|
|
|
#endif
|
|
#endif
|
|
|
#if $[filter_dirs]
|
|
#if $[filter_dirs]
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[filter_dirs]]
|
|
|
|
|
+ #else
|
|
|
$[TAB]rm -rf $[filter_dirs]
|
|
$[TAB]rm -rf $[filter_dirs]
|
|
|
|
|
+ #endif
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
// We need a rule for each directory we might need to make. This
|
|
// We need a rule for each directory we might need to make. This
|
|
@@ -270,16 +292,26 @@ $[TAB]rm -rf $[filter_dirs]
|
|
|
$[install_other_dirs] \
|
|
$[install_other_dirs] \
|
|
|
]
|
|
]
|
|
|
$[directory] :
|
|
$[directory] :
|
|
|
|
|
+#if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB] if not exist $[osfilename $[directory]] mkdir $[osfilename $[directory]]
|
|
|
|
|
+#else
|
|
|
$[TAB]@test -d $[directory] || echo mkdir -p $[directory]
|
|
$[TAB]@test -d $[directory] || echo mkdir -p $[directory]
|
|
|
$[TAB]@test -d $[directory] || mkdir -p $[directory]
|
|
$[TAB]@test -d $[directory] || mkdir -p $[directory]
|
|
|
|
|
+#endif
|
|
|
|
|
|
|
|
// Sometimes we need a target to depend on the directory existing, without
|
|
// Sometimes we need a target to depend on the directory existing, without
|
|
|
// being fooled by the directory's modification times. We use this
|
|
// being fooled by the directory's modification times. We use this
|
|
|
// phony timestamp file to achieve that.
|
|
// phony timestamp file to achieve that.
|
|
|
$[directory]/stamp :
|
|
$[directory]/stamp :
|
|
|
|
|
+#if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB] if not exist $[osfilename $[directory]] mkdir $[osfilename $[directory]]
|
|
|
|
|
+$[TAB]$[TOUCH_CMD] $[osfilename $[directory]/stamp]
|
|
|
|
|
+#else
|
|
|
$[TAB]@test -d $[directory] || echo mkdir -p $[directory]
|
|
$[TAB]@test -d $[directory] || echo mkdir -p $[directory]
|
|
|
$[TAB]@test -d $[directory] || mkdir -p $[directory]
|
|
$[TAB]@test -d $[directory] || mkdir -p $[directory]
|
|
|
-$[TAB]@touch $[directory]/stamp
|
|
|
|
|
|
|
+$[TAB]$[TOUCH_CMD] $[directory]/stamp
|
|
|
|
|
+#endif
|
|
|
|
|
+
|
|
|
#end directory
|
|
#end directory
|
|
|
|
|
|
|
|
// Decompressing compressed files.
|
|
// Decompressing compressed files.
|
|
@@ -288,7 +320,7 @@ $[TAB]@touch $[directory]/stamp
|
|
|
#define target $[gz:%.gz=%]
|
|
#define target $[gz:%.gz=%]
|
|
|
#define source $[gz]
|
|
#define source $[gz]
|
|
|
$[target] : $[source]
|
|
$[target] : $[source]
|
|
|
-$[TAB]rm -f $[target]
|
|
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[target]]
|
|
|
$[TAB]gunzip $[GUNZIP_OPTS] < $[source] > $[target]
|
|
$[TAB]gunzip $[GUNZIP_OPTS] < $[source] > $[target]
|
|
|
|
|
|
|
|
#end gz
|
|
#end gz
|
|
@@ -410,7 +442,11 @@ $[TAB]$[SOFT2EGG] $[SOFT2EGG_OPTS] $[if $[SOFTIMAGE_RSRC],-r "$[osfilename $[SOF
|
|
|
#define source $[word $[i],$[SOURCES]]
|
|
#define source $[word $[i],$[SOURCES]]
|
|
|
#define target $[word $[i],$[TARGETS]]
|
|
#define target $[word $[i],$[TARGETS]]
|
|
|
$[target] : $[source]
|
|
$[target] : $[source]
|
|
|
-$[TAB]cp $[source] $[target]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[osfilename $[source]] $[osfilename $[target]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[source] $[target]
|
|
|
|
|
+ #endif
|
|
|
#end i
|
|
#end i
|
|
|
#end copy_egg
|
|
#end copy_egg
|
|
|
|
|
|
|
@@ -435,7 +471,11 @@ $[TAB]$[COMMAND]
|
|
|
// first one.
|
|
// first one.
|
|
|
#foreach egg $[notdir $[wordlist 2,9999,$[SOURCES]]]
|
|
#foreach egg $[notdir $[wordlist 2,9999,$[SOURCES]]]
|
|
|
$[TARGET_DIR]/$[egg] : $[target] $[TARGET_DIR]/stamp
|
|
$[TARGET_DIR]/$[egg] : $[target] $[TARGET_DIR]/stamp
|
|
|
-$[TAB]touch $[TARGET_DIR]/$[egg]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[TOUCH_CMD] $[osfilename $[TARGET_DIR]/$[egg]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[TOUCH_CMD] $[TARGET_DIR]/$[egg]
|
|
|
|
|
+ #endif
|
|
|
#end egg
|
|
#end egg
|
|
|
|
|
|
|
|
// And this is the actual optchar pass.
|
|
// And this is the actual optchar pass.
|
|
@@ -453,7 +493,11 @@ $[TAB]$[COMMAND]
|
|
|
// first one.
|
|
// first one.
|
|
|
#foreach egg $[notdir $[wordlist 2,9999,$[SOURCES]]]
|
|
#foreach egg $[notdir $[wordlist 2,9999,$[SOURCES]]]
|
|
|
$[TARGET_DIR]/$[egg] : $[target] $[TARGET_DIR]/stamp
|
|
$[TARGET_DIR]/$[egg] : $[target] $[TARGET_DIR]/stamp
|
|
|
-$[TAB]touch $[TARGET_DIR]/$[egg]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[TOUCH_CMD] $[osfilename $[TARGET_DIR]/$[egg]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[TOUCH_CMD] $[TARGET_DIR]/$[egg]
|
|
|
|
|
+ #endif
|
|
|
#end egg
|
|
#end egg
|
|
|
|
|
|
|
|
// And this is the actual optchar pass.
|
|
// And this is the actual optchar pass.
|
|
@@ -476,7 +520,7 @@ $[TAB]egg-palettize $[PALETTIZE_OPTS] -af $[texattrib_file] -dr $[install_dir] -
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
$[pt] :
|
|
$[pt] :
|
|
|
-$[TAB]touch $[pt]
|
|
|
|
|
|
|
+$[TAB]$[TOUCH_CMD] $[pt]
|
|
|
|
|
|
|
|
#end egg
|
|
#end egg
|
|
|
#end install_egg
|
|
#end install_egg
|
|
@@ -516,8 +560,13 @@ $[TAB]egg2bam $[EGG2BAM_OPTS] -NC -o $[target] $[source]
|
|
|
#define dest $[install_model_dir]
|
|
#define dest $[install_model_dir]
|
|
|
$[dest]/$[local] : $[sourcedir]/$[local]
|
|
$[dest]/$[local] : $[sourcedir]/$[local]
|
|
|
// cd ./$[sourcedir] && $[INSTALL]
|
|
// cd ./$[sourcedir] && $[INSTALL]
|
|
|
-$[TAB]rm -f $[dest]/$[local]
|
|
|
|
|
-$[TAB]cp $[sourcedir]/$[local] $[dest]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[dest]/$[local]]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[osfilename $[sourcedir]/$[local]] $[osfilename $[dest]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[dest]/$[local]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[sourcedir]/$[local] $[dest]
|
|
|
|
|
+ #endif
|
|
|
|
|
|
|
|
#end egg
|
|
#end egg
|
|
|
#if $[LANGUAGES]
|
|
#if $[LANGUAGES]
|
|
@@ -536,8 +585,13 @@ $[TAB]cp $[sourcedir]/$[local] $[dest]
|
|
|
#define dest $[install_model_dir]
|
|
#define dest $[install_model_dir]
|
|
|
$[dest]/$[remote] : $[sourcedir]/$[local]
|
|
$[dest]/$[remote] : $[sourcedir]/$[local]
|
|
|
// cd ./$[sourcedir] && $[INSTALL]
|
|
// cd ./$[sourcedir] && $[INSTALL]
|
|
|
-$[TAB]rm -f $[dest]/$[remote]
|
|
|
|
|
-$[TAB]cp $[sourcedir]/$[local] $[dest]/$[remote]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[dest]/$[remote]]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[osfilename $[sourcedir]/$[local]] $[osfilename $[dest]/$[remote]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[dest]/$[remote]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[sourcedir]/$[local] $[dest]/$[remote]
|
|
|
|
|
+ #endif
|
|
|
|
|
|
|
|
#end egg
|
|
#end egg
|
|
|
#endif
|
|
#endif
|
|
@@ -553,7 +607,11 @@ uninstall-bam :
|
|
|
#endif
|
|
#endif
|
|
|
#define files $[patsubst %.egg,$[install_model_dir]/%.bam,$[generic_egglist] $[language_egglist]]
|
|
#define files $[patsubst %.egg,$[install_model_dir]/%.bam,$[generic_egglist] $[language_egglist]]
|
|
|
#if $[files]
|
|
#if $[files]
|
|
|
-$[TAB]rm -f $[files]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[files]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[files]
|
|
|
|
|
+ #endif
|
|
|
#endif
|
|
#endif
|
|
|
#end install_egg
|
|
#end install_egg
|
|
|
|
|
|
|
@@ -566,8 +624,13 @@ $[TAB]rm -f $[files]
|
|
|
#define dest $[install_model_dir]
|
|
#define dest $[install_model_dir]
|
|
|
$[dest]/$[remote] : $[local]
|
|
$[dest]/$[remote] : $[local]
|
|
|
// $[INSTALL]
|
|
// $[INSTALL]
|
|
|
-$[TAB]rm -f $[dest]/$[remote]
|
|
|
|
|
-$[TAB]cp $[local] $[dest]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[dest]/$[remote]]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[osfilename $[local]] $[osfilename $[dest]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[dest]/$[remote]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[local] $[dest]
|
|
|
|
|
+ #endif
|
|
|
|
|
|
|
|
#end file
|
|
#end file
|
|
|
#if $[LANGUAGES]
|
|
#if $[LANGUAGES]
|
|
@@ -585,8 +648,13 @@ $[TAB]cp $[local] $[dest]
|
|
|
#define dest $[install_model_dir]
|
|
#define dest $[install_model_dir]
|
|
|
$[dest]/$[remote] : $[local]
|
|
$[dest]/$[remote] : $[local]
|
|
|
// cd ./$[sourcedir] && $[INSTALL]
|
|
// cd ./$[sourcedir] && $[INSTALL]
|
|
|
-$[TAB]rm -f $[dest]/$[remote]
|
|
|
|
|
-$[TAB]cp $[local] $[dest]/$[remote]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[dest]/$[remote]]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[osfilename $[local]] $[osfilename $[dest]/$[remote]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[dest]/$[remote]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[local] $[dest]/$[remote]
|
|
|
|
|
+ #endif
|
|
|
|
|
|
|
|
#end file
|
|
#end file
|
|
|
#endif
|
|
#endif
|
|
@@ -602,7 +670,11 @@ uninstall-other:
|
|
|
#endif
|
|
#endif
|
|
|
#define files $[patsubst %,$[install_model_dir]/%,$[generic_sources] $[language_sources]]
|
|
#define files $[patsubst %,$[install_model_dir]/%,$[generic_sources] $[language_sources]]
|
|
|
#if $[files]
|
|
#if $[files]
|
|
|
-$[TAB]rm -f $[files]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[files]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[files]
|
|
|
|
|
+ #endif
|
|
|
#endif
|
|
#endif
|
|
|
#end install_dna
|
|
#end install_dna
|
|
|
|
|
|
|
@@ -616,8 +688,13 @@ $[TAB]rm -f $[files]
|
|
|
#define dest $[install_model_dir]
|
|
#define dest $[install_model_dir]
|
|
|
$[dest]/$[remote] : $[local]
|
|
$[dest]/$[remote] : $[local]
|
|
|
// $[INSTALL]
|
|
// $[INSTALL]
|
|
|
-$[TAB]rm -f $[dest]/$[remote]
|
|
|
|
|
-$[TAB]cp $[local] $[dest]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[dest]/$[remote]]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[osfilename $[local]] $[osfilename $[dest]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[dest]/$[remote]
|
|
|
|
|
+$[TAB]$[COPY_CMD] $[local] $[dest]
|
|
|
|
|
+ #endif
|
|
|
|
|
|
|
|
#end file
|
|
#end file
|
|
|
#end install_audio install_icons install_shader install_misc
|
|
#end install_audio install_icons install_shader install_misc
|
|
@@ -627,7 +704,11 @@ uninstall-other:
|
|
|
#forscopes install_audio install_icons install_shader install_misc
|
|
#forscopes install_audio install_icons install_shader install_misc
|
|
|
#define files $[patsubst %,$[install_model_dir]/%,$[SOURCES]]
|
|
#define files $[patsubst %,$[install_model_dir]/%,$[SOURCES]]
|
|
|
#if $[files]
|
|
#if $[files]
|
|
|
-$[TAB]rm -f $[files]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[files]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[files]
|
|
|
|
|
+ #endif
|
|
|
#endif
|
|
#endif
|
|
|
#end install_audio install_icons install_shader install_misc
|
|
#end install_audio install_icons install_shader install_misc
|
|
|
|
|
|
|
@@ -714,7 +795,11 @@ $[TAB]egg-palettize $[PALETTIZE_OPTS] -af $[texattrib_file] -dm $[install_dir]/%
|
|
|
# undo-pal : blow away all the palettization information and start fresh.
|
|
# undo-pal : blow away all the palettization information and start fresh.
|
|
|
#
|
|
#
|
|
|
undo-pal : clean-pal
|
|
undo-pal : clean-pal
|
|
|
-$[TAB]rm -f $[texattrib_file:%.txa=%.boo]
|
|
|
|
|
|
|
+ #if $[eq $[BUILD_TYPE], nmake]
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[osfilename $[texattrib_file:%.txa=%.boo]]
|
|
|
|
|
+ #else
|
|
|
|
|
+$[TAB]$[DEL_CMD] $[texattrib_file:%.txa=%.boo]
|
|
|
|
|
+ #endif
|
|
|
|
|
|
|
|
#
|
|
#
|
|
|
# pi : report the palettization information to standard output for the
|
|
# pi : report the palettization information to standard output for the
|