Skip to content

Commit

Permalink
Updated for nuget-based release
Browse files Browse the repository at this point in the history
  • Loading branch information
bcarrier committed Nov 3, 2020
1 parent b46aa8b commit aaf5129
Showing 1 changed file with 8 additions and 17 deletions.
25 changes: 8 additions & 17 deletions release/release-win.pl
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
# This only builds the 32-bit, release target
#
# Assumes:
#- libewf, libvmdk, and libvhdi are configured and built
#- The correct msbuild is in the PATH
#-- VS2015 and VS2008 put this in different places. If VS2008 is found first, you'll get errors
# about not finding the 140_xp platform.
#-- The easiest way to do this is to launch Cygwin using the appropriate batch file, which sets
# the correct environment variables.
#- Nuget exe commandline is installed and on path
#
# This requires Cygwin with:
# - git
Expand All @@ -21,8 +21,7 @@

use strict;

my $TESTING = 0;
print "TESTING MODE (no commits)\n" if ($TESTING);
# Use 'no-tag' as the tag name to do basic testing

unless (@ARGV == 1) {
print stderr "Missing arguments: version\n";
Expand All @@ -47,18 +46,6 @@
#die "Missing redist dir $REDIST_LOC" unless (-d "$REDIST_LOC");


# Verify LIBX libraries exist / built
die "LIBEWF missing" unless (-d "$ENV{'LIBEWF_HOME'}");
die "libewf dll missing"
unless (-e "$ENV{'LIBEWF_HOME'}/msvscpp/Release/libewf.dll" );

die "libvhdi dll missing"
unless (-e "$ENV{'LIBVHDI_HOME'}/msvscpp/Release/libvhdi.dll" );

die "libvhdi dll missing"
unless (-e "$ENV{'LIBVMDK_HOME'}/msvscpp/Release/libvmdk.dll" );


#######################

# Function to execute a command and send output to pipe
Expand Down Expand Up @@ -165,10 +152,14 @@ sub build_core {

die "Release folder not deleted" if (-x "Release/fls.exe");


# Get Dependencies
`nuget restore tsk-win.sln`;

# 2008 version
# `vcbuild /errfile:BuildErrors.txt tsk-win.sln "Release|Win32"`;
# 2010/2015 version
`msbuild.exe tsk-win.sln /m /p:Configuration=Release /clp:ErrorsOnly /nologo > BuildErrors.txt`;
`msbuild.exe tsk-win.sln /m /p:Configuration=Release /p:platform=Win32 /clp:ErrorsOnly /nologo > BuildErrors.txt`;
die "Build errors -- check win32/BuildErrors.txt" if (-s "BuildErrors.txt");

# Do a basic check on some of the executables
Expand Down Expand Up @@ -240,4 +231,4 @@ sub package_core {

update_code();
build_core();
package_core();
package_core();

0 comments on commit aaf5129

Please sign in to comment.