Added touch.pl for WIN32 builds (needed for newest cygwin make).
This commit is contained in:
@@ -20,6 +20,7 @@ TEMPLATES += top/config/RULES_TOP
|
||||
TEMPLATES += top/config/makeDbDepends.pl
|
||||
TEMPLATES += top/config/convertRelease.pl
|
||||
TEMPLATES += top/config/replaceVAR.pl
|
||||
TEMPLATES += top/config/touch.pl
|
||||
|
||||
TEMPLATES += top/exampleApp/Makefile
|
||||
TEMPLATES += top/exampleApp/Db/Makefile
|
||||
|
||||
@@ -11,7 +11,7 @@ REPLACEVAR = $(PERL) $(TOP)/config/replaceVAR.pl
|
||||
ifndef WIN32
|
||||
TOUCH = touch
|
||||
else
|
||||
TOUCH = type NUL >>
|
||||
TOUCH = $(PERL) $(TOP)/config/touch.pl
|
||||
endif
|
||||
|
||||
#-----------------------------------------------------------------
|
||||
|
||||
Executable
+31
@@ -0,0 +1,31 @@
|
||||
#!/usr/bin/perl
|
||||
#
|
||||
# unix touch in Perl
|
||||
|
||||
use File::Copy;
|
||||
use File::Basename;
|
||||
|
||||
sub Usage
|
||||
{
|
||||
my ($txt) = @_;
|
||||
|
||||
print "Usage:\n";
|
||||
print "\ttouch file [ file2 file3 ...]\n";
|
||||
print "\nError: $txt\n" if $txt;
|
||||
|
||||
exit 2;
|
||||
}
|
||||
|
||||
# need at least one arg: ARGV[0]
|
||||
Usage("need more args") if $#ARGV < 0;
|
||||
|
||||
@targets=@ARGV[0..$#ARGV];
|
||||
|
||||
foreach $file ( @targets )
|
||||
{
|
||||
open(OUT,">$file") or die "$! creating $file";
|
||||
#print OUT "NUL\n";
|
||||
close OUT;
|
||||
}
|
||||
|
||||
# EOF touch.pl
|
||||
Reference in New Issue
Block a user