Skip to content
This repository has been archived by the owner on Jun 22, 2023. It is now read-only.

Commit

Permalink
Changes to build locally
Browse files Browse the repository at this point in the history
- Renamed GeoAPI.Net35CF project to GeoAPI.CF.
- Removed GeoAPI.Net35 project.
- Updated NuGet package specification to include net35-cf and new version number.
- New scripts to build libraries and NuGet package.
- Updated NuGet executable.
  • Loading branch information
Fabrício Godoy committed Oct 27, 2016
1 parent 9a4eae3 commit 6fcb7a2
Show file tree
Hide file tree
Showing 11 changed files with 188 additions and 460 deletions.
Binary file modified .nuget/NuGet.exe
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
<FileAlignment>512</FileAlignment>
<WarningLevel>4</WarningLevel>
<GenerateSerializationAssemblies>Off</GenerateSerializationAssemblies>
<DocumentationFile>$(SolutionDir)$(Configuration)\$(TargetFrameworkIdentifier)$(TargetFrameworkVersion)\$(PlatformFamilyName)\GeoAPI.XML</DocumentationFile>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
Expand All @@ -45,6 +46,7 @@
<FileAlignment>512</FileAlignment>
<WarningLevel>4</WarningLevel>
<GenerateSerializationAssemblies>Off</GenerateSerializationAssemblies>
<DocumentationFile>$(SolutionDir)$(Configuration)\$(TargetFrameworkVersion)\$(PlatformFamilyName)\GeoAPI.XML</DocumentationFile>
</PropertyGroup>
<ItemGroup>
<Reference Include="mscorlib" />
Expand Down
349 changes: 0 additions & 349 deletions GeoAPI.Net35/GeoAPI.Net35.csproj

This file was deleted.

3 changes: 3 additions & 0 deletions GeoAPI.NetCore/Consts.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ internal static class Consts
#elif NET35
public const string Product = "GeoAPI.Net35";
public const string Guid = "8de32941-f422-41e6-a7e5-964bb4ab2d3b";
#elif NET20
public const string Product = "GeoAPI.Net20";
public const string Guid = "2ac6149a-cb66-48d3-9c2b-6a5c19dcf203";
#elif NET_CORE
public const string Product = "GeoAPI.NetCore";
public const string Guid = "eef37cab-4f83-4366-8533-3d7c16b449c7";
Expand Down
11 changes: 4 additions & 7 deletions GeoAPI.NetCore/ValueParser.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
using System;
using System.Linq;
using System.Collections.Generic;
using System.Text;

// Ref: http://www.yortondotnet.com/2009/11/tryparse-for-compact-framework.html

Expand Down Expand Up @@ -68,7 +65,7 @@ public static bool TryParse(string s, out byte result)
/// <param name="result">The result of the parsed string, or zero if parsing failed.</param>
/// <returns>A boolean value indicating whether or not the parse succeeded.</returns>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "s")]
public static bool TryParse(string s, out Int16 result)
public static bool TryParse(string s, out short result)
{
bool retVal = false;
#if WindowsCE
Expand All @@ -80,7 +77,7 @@ public static bool TryParse(string s, out Int16 result)
catch (FormatException) { result = 0; }
catch (InvalidCastException) { result = 0; }
#else
retVal = Int16.TryParse(s, out result);
retVal = short.TryParse(s, out result);
#endif
return retVal;
}
Expand All @@ -92,7 +89,7 @@ public static bool TryParse(string s, out Int16 result)
/// <param name="result">The result of the parsed string, or zero if parsing failed.</param>
/// <returns>A boolean value indicating whether or not the parse succeeded.</returns>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "s")]
public static bool TryParse(string s, out Int64 result)
public static bool TryParse(string s, out long result)
{
bool retVal = false;
#if WindowsCE
Expand All @@ -104,7 +101,7 @@ public static bool TryParse(string s, out Int64 result)
catch (FormatException) { result = 0; }
catch (InvalidCastException) { result = 0; }
#else
retVal = Int64.TryParse(s, out result);
retVal = long.TryParse(s, out result);
#endif
return retVal;
}
Expand Down
193 changes: 99 additions & 94 deletions GeoAPI.nuspec

Large diffs are not rendered by default.

8 changes: 0 additions & 8 deletions GeoAPI.sln
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Build", "Build", "{D0DCE6F6
EndProject
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "GeoAPI.NetCore", "GeoAPI.NetCore\GeoAPI.NetCore.xproj", "{EEF37CAB-4F83-4366-8533-3D7C16B449C7}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GeoAPI.Net35", "GeoAPI.Net35\GeoAPI.Net35.csproj", "{8DE32941-F422-41E6-A7E5-964BB4AB2D3B}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
CIBuild|Any CPU = CIBuild|Any CPU
Expand All @@ -41,12 +39,6 @@ Global
{EEF37CAB-4F83-4366-8533-3D7C16B449C7}.Debug|Any CPU.Build.0 = Debug|Any CPU
{EEF37CAB-4F83-4366-8533-3D7C16B449C7}.Release|Any CPU.ActiveCfg = Release|Any CPU
{EEF37CAB-4F83-4366-8533-3D7C16B449C7}.Release|Any CPU.Build.0 = Release|Any CPU
{8DE32941-F422-41E6-A7E5-964BB4AB2D3B}.CIBuild|Any CPU.ActiveCfg = Release|Any CPU
{8DE32941-F422-41E6-A7E5-964BB4AB2D3B}.CIBuild|Any CPU.Build.0 = Release|Any CPU
{8DE32941-F422-41E6-A7E5-964BB4AB2D3B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{8DE32941-F422-41E6-A7E5-964BB4AB2D3B}.Debug|Any CPU.Build.0 = Debug|Any CPU
{8DE32941-F422-41E6-A7E5-964BB4AB2D3B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{8DE32941-F422-41E6-A7E5-964BB4AB2D3B}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
2 changes: 1 addition & 1 deletion GeoAPI.vs2008.sln
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

Microsoft Visual Studio Solution File, Format Version 10.00
# Visual Studio 2008
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GeoAPI.Net35CF", "GeoAPI.Net35CF\GeoAPI.Net35CF.csproj", "{FC13A43A-6170-4EF5-9ADA-EB44388DDC9E}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GeoAPI.CF", "GeoAPI.CF\GeoAPI.CF.csproj", "{FC13A43A-6170-4EF5-9ADA-EB44388DDC9E}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Expand Down
11 changes: 11 additions & 0 deletions NuGet.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
echo off

set SolutionDir=%~dp0
set GeoAPIVersion=1.7.5
set AsmFileVersion=%GeoAPIVersion%
set NuGetOutDir=%SolutionDir%Release
set NuGetVersion=%AsmFileVersion%
set NuGetCommand=%SolutionDir%.nuget\NuGet.exe

%NuGetCommand% update -self
%NuGetCommand% pack GeoAPI.nuspec -Version %NuGetVersion% -outputdirectory %NuGetOutDir% -symbols
2 changes: 1 addition & 1 deletion TeamCity.targets
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<PropertyGroup>
<SolutionFile>$(MSBuildThisFileDirectory)GeoAPI.sln</SolutionFile>
<SolutionDir>$(MSBuildThisFileDirectory)</SolutionDir>
<GeoAPIVersion Condition=" '$(GeoAPIVersion)' == '' ">1.7.4</GeoAPIVersion>
<GeoAPIVersion Condition=" '$(GeoAPIVersion)' == '' ">1.7.5</GeoAPIVersion>
<AsmFileVersion Condition=" '$(AsmFileVersion)' == '' ">$(GeoAPIVersion)</AsmFileVersion>
<NuGetOutDir>"$(MSBuildProjectDirectory)\Release"</NuGetOutDir>
<NuGetVersion Condition=" '$(NuGetVersion)' == '' ">$(AsmFileVersion)</NuGetVersion>
Expand Down
67 changes: 67 additions & 0 deletions build.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
echo off

set msbuild="C:\Program Files (x86)\MSBuild\14.0\bin\msbuild"
if not exist %msbuild% (
set msbuild="C:\Program Files (x86)\MSBuild\12.0\bin\msbuild"
if not exist %msbuild% (
echo "Error trying to find MSBuild executable"
exit 1
)
)
set SolutionDir=%~dp0

echo building all projects in the solution (Release)

set Target=v2.0
set OutputPath="%SolutionDir%Release\%Target%\AnyCPU"
set ObjOutputPath="%SolutionDir%GeoAPI\obj\%Target%\"
set Constants=TRACE;NET20
echo building for .NET Framework %Target%
rmdir /s/q "%OutputPath%" 2> nul
%msbuild% %SolutionDir%GeoAPI.sln /target:GeoAPI /property:Configuration=Release;TargetFrameworkVersion=%Target%;TargetFrameworkProfile=;OutputPath=%OutputPath%\;DefineConstants="%Constants%;BaseIntermediateOutputPath=%ObjOutputPath%" /verbosity:minimal

set Target=v3.5
set OutputPath="%SolutionDir%Release\%Target%\AnyCPU"
set ObjOutputPath="%SolutionDir%GeoAPI\obj\%Target%\"
set Constants=%Constants%;NET35
echo building for .NET Framework %Target%
rmdir /s/q "%OutputPath%" 2> nul
%msbuild% %SolutionDir%GeoAPI.sln /target:GeoAPI /property:Configuration=Release;TargetFrameworkVersion=%Target%;TargetFrameworkProfile=;OutputPath=%OutputPath%\;DefineConstants="%Constants%;BaseIntermediateOutputPath=%ObjOutputPath%" /verbosity:minimal

set Target=v4.0
set OutputPath="%SolutionDir%Release\%Target%\AnyCPU"
set ObjOutputPath="%SolutionDir%GeoAPI\obj\%Target%\"
set Constants=%Constants%;NET40
echo building for .NET Framework %Target%
rmdir /s/q "%OutputPath%" 2> nul
%msbuild% %SolutionDir%GeoAPI.sln /target:GeoAPI /property:Configuration=Release;TargetFrameworkVersion=%Target%;TargetFrameworkProfile=;OutputPath=%OutputPath%\;DefineConstants="%Constants%;BaseIntermediateOutputPath=%ObjOutputPath%" /verbosity:minimal

set Target=v4.0.3
set OutputPath="%SolutionDir%Release\%Target%\AnyCPU"
set ObjOutputPath="%SolutionDir%GeoAPI\obj\%Target%\"
set Constants=%Constants%
echo building for .NET Framework %Target%
rmdir /s/q "%OutputPath%" 2> nul
%msbuild% %SolutionDir%GeoAPI.sln /target:GeoAPI /property:Configuration=Release;TargetFrameworkVersion=%Target%;TargetFrameworkProfile=;OutputPath=%OutputPath%\;DefineConstants="%Constants%;BaseIntermediateOutputPath=%ObjOutputPath%" /verbosity:minimal

set Target=v4.5
set OutputPath="%SolutionDir%Release\%Target%\AnyCPU"
set ObjOutputPath="%SolutionDir%GeoAPI\obj\%Target%\"
set Constants=%Constants%
echo building for .NET Framework %Target%
rmdir /s/q "%OutputPath%" 2> nul
%msbuild% %SolutionDir%GeoAPI.sln /target:GeoAPI /property:Configuration=Release;TargetFrameworkVersion=%Target%;TargetFrameworkProfile=;OutputPath=%OutputPath%\;DefineConstants="%Constants%;BaseIntermediateOutputPath=%ObjOutputPath%" /verbosity:minimal

set Target=v4.0
set Profile=Profile336
set OutputPath="%SolutionDir%Release\PCL\AnyCPU"
set ObjOutputPath="%SolutionDir%GeoAPI\obj\PCL\"
set Constants=TRACE;PCL
echo building for .NET Framework %Target% %Profile%
rmdir /s/q "%OutputPath%" 2> nul
%msbuild% %SolutionDir%GeoAPI.sln /target:GeoAPI_PCL /property:Configuration=Release;TargetFrameworkVersion=%Target%;TargetFrameworkProfile=%Profile%;OutputPath=%OutputPath%\;DefineConstants="%Constants%;BaseIntermediateOutputPath=%ObjOutputPath%" /verbosity:minimal

REM echo building for .NET Core
REM %msbuild% %SolutionDir%GeoAPI.sln /target:GeoAPI_NetCore /verbosity:minimal

echo build complete.

0 comments on commit 6fcb7a2

Please sign in to comment.