Error when running prepare.bat v2.2

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
12 years ago
Actually, no.
12 years ago
Hi,

Newby here. I have been playing around with nop for a few days and I love it!

I decided to have a look at the code and have also ran into the problem when running prepare.bat


Build FAILED.

       "D:\projects\mishu\build\nop.proj" (default target) (1) ->
       "D:\projects\mishu\NopCommerce.sln" (default target) (2) ->
       "D:\projects\mishu\Libraries\Nop.Services\Nop.Services.csproj" (default
       target) (4) ->
       (GenerateSerializationAssemblies target) ->
         SGEN : error : Could not load file or assembly 'file:///D:\projects\mi
       shu\packages\EPPlus.2.9.0.1\lib\2.0\EPPlus.dll' or one of its dependenci
       es. Operation is not supported. (Exception from HRESULT: 0x80131515) [D:
       \projects\mishu\Libraries\Nop.Services\Nop.Services.csproj]

    0 Warning(s)
    1 Error(s)

Time Elapsed 00:00:07.67
Press any key to continue . . .

Any help would be much appreciated.

PS. I removed the EPPlus reference and re-added. This did not help.
12 years ago
What Windows do you use (XP, 7, 2003, etc)?
12 years ago
I ran into this same situation when trying to compile the release version of V2.3. It appears it is a problem with SGEN running on a blocked dll. I followed the directions posted on this website and it fixed the issue for me.

http://stackoverflow.com/questions/3007190/vsts-2010-sgen-error-could-not-load-file-or-assembly-exception-from-hresult

David
12 years ago
I had the same issue with version 2.3, and I tried David's suggestion and it works.

I was able to run prepare and deploy.bat for a while, and suddenly after a weekend, neither option works. Not sure why, and I kept thinking maybe I "thought" it used to work.

Anyway, the stackOverflow solution definitely got rid of my problems. I have 3 .dll that I need to "unblock" thru window explorer.

packages\FluentValidation.2.0.0.0\lib\NET35\FluentValidation.dll
packages\EPPlus.2.9.0.1\lib\2.0EPPlus.dll
packages\nopCommerceCustom\itextsharp.dll

Thanks David
12 years ago
OK this is he latest.  I wnet into the presentation/bin/ directory and unblocked every dll that was blocked.  I get the same error.

Here is the whole dump file.
----

C:\Users\Administrator\Downloads\NopCommerceWeb\build>C:\Windows\Microsoft.NET\F
ramework\v4.0.30319\MSBuild.exe nop.proj /maxcpucount /l:FileLogger,Microsoft.Bu
ild.Engine;logfile=log.log
Microsoft (R) Build Engine Version 4.0.30319.1
[Microsoft .NET Framework, Version 4.0.30319.261]
Copyright (C) Microsoft Corporation 2007. All rights reserved.

Build started 5/7/2012 7:28:02 PM.
     1>Project "C:\Users\Administrator\Downloads\NopCommerceWeb\build\nop.proj"
        on node 1 (default targets).
     1>Build:
         Building Everything
     1>Project "C:\Users\Administrator\Downloads\NopCommerceWeb\build\nop.proj"
        (1) is building "C:\Users\Administrator\Downloads\NopCommerceWeb\NopCom
       merce.sln" (2) on node 1 (default targets).
     2>ValidateSolutionConfiguration:
         Building solution configuration "Release|Any CPU".
     2>Project "C:\Users\Administrator\Downloads\NopCommerceWeb\NopCommerce.sln
       " (2) is building "C:\Users\Administrator\Downloads\NopCommerceWeb\Tests
       \Nop.Tests\Nop.Tests.csproj" (3) on node 2 (default targets).
     3>GenerateTargetFrameworkMonikerAttribute:
       Skipping target "GenerateTargetFrameworkMonikerAttribute" because all ou
       tput files are up-to-date with respect to the input files.
       CoreCompile:
       Skipping target "CoreCompile" because all output files are up-to-date wi
       th respect to the input files.
       CopyFilesToOutputDirectory:
         Nop.Tests -> C:\Users\Administrator\Downloads\NopCommerceWeb\Tests\Nop
         .Tests\bin\Release\Nop.Tests.dll
     2>Project "C:\Users\Administrator\Downloads\NopCommerceWeb\NopCommerce.sln
       " (2) is building "C:\Users\Administrator\Downloads\NopCommerceWeb\Libra
       ries\Nop.Core\Nop.Core.csproj" (6) on node 1 (default targets).
     6>GenerateTargetFrameworkMonikerAttribute:
       Skipping target "GenerateTargetFrameworkMonikerAttribute" because all ou
       tput files are up-to-date with respect to the input files.
     3>Done Building Project "C:\Users\Administrator\Downloads\NopCommerceWeb\T
       ests\Nop.Tests\Nop.Tests.csproj" (default targets).
     6>CoreCompile:
       Skipping target "CoreCompile" because all output files are up-to-date wi
       th respect to the input files.
       CopyFilesToOutputDirectory:
         Nop.Core -> C:\Users\Administrator\Downloads\NopCommerceWeb\Libraries\
         Nop.Core\bin\Release\Nop.Core.dll
     6>Done Building Project "C:\Users\Administrator\Downloads\NopCommerceWeb\L
       ibraries\Nop.Core\Nop.Core.csproj" (default targets).
     2>Project "C:\Users\Administrator\Downloads\NopCommerceWeb\NopCommerce.sln
       " (2) is building "C:\Users\Administrator\Downloads\NopCommerceWeb\Libra
       ries\Nop.Data\Nop.Data.csproj" (5) on node 5 (default targets).
     5>GenerateTargetFrameworkMonikerAttribute:
       Skipping target "GenerateTargetFrameworkMonikerAttribute" because all ou
       tput files are up-to-date with respect to the input files.
       CoreCompile:
       Skipping target "CoreCompile" because all output files are up-to-date wi
       th respect to the input files.
       CopyFilesToOutputDirectory:
         Nop.Data -> C:\Users\Administrator\Downloads\NopCommerceWeb\Libraries\
         Nop.Data\bin\Release\Nop.Data.dll
     5>Done Building Project "C:\Users\Administrator\Downloads\NopCommerceWeb\L
       ibraries\Nop.Data\Nop.Data.csproj" (default targets).
     2>Project "C:\Users\Administrator\Downloads\NopCommerceWeb\NopCommerce.sln
       " (2) is building "C:\Users\Administrator\Downloads\NopCommerceWeb\Tests
       \Nop.Core.Tests\Nop.Core.Tests.csproj" (7) on node 4 (default targets).
     7>GenerateTargetFrameworkMonikerAttribute:
       Skipping target "GenerateTargetFrameworkMonikerAttribute" because all ou
       tput files are up-to-date with respect to the input files.
       CoreCompile:
       Skipping target "CoreCompile" because all output files are up-to-date wi
       th respect to the input files.
       _CopyAppConfigFile:
       Skipping target "_CopyAppConfigFile" because all output files are up-to-
       date with respect to the input files.
       CopyFilesToOutputDirectory:
         Nop.Core.Tests -> C:\Users\Administrator\Downloads\NopCommerceWeb\Test
         s\Nop.Core.Tests\bin\Release\Nop.Core.Tests.dll
     7>Done Building Project "C:\Users\Administrator\Downloads\NopCommerceWeb\T
       ests\Nop.Core.Tests\Nop.Core.Tests.csproj" (default targets).
     2>Project "C:\Users\Administrator\Downloads\NopCommerceWeb\NopCommerce.sln
       " (2) is building "C:\Users\Administrator\Downloads\NopCommerceWeb\Libra
       ries\Nop.Services\Nop.Services.csproj" (10) on node 6 (default targets).
    10>GenerateTargetFrameworkMonikerAttribute:
       Skipping target "GenerateTargetFrameworkMonikerAttribute" because all ou
       tput files are up-to-date with respect to the input files.
       CoreCompile:
       Skipping target "CoreCompile" because all output files are up-to-date wi
       th respect to the input files.
       GenerateSerializationAssemblies:
         C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\bin\NETFX 4.0 Tool
         s\sgen.exe /assembly:C:\Users\Administrator\Downloads\NopCommerceWeb\L
         ibraries\Nop.Services\obj\Release\Nop.Services.dll /proxytypes /refere
         nce:C:\Users\Administrator\Downloads\NopCommerceWeb\packages\EPPlus.3.
         0.0.2\lib\net20\EPPlus.dll /reference:C:\Users\Administrator\Downloads
         \NopCommerceWeb\packages\nopCommerceCustom\itextsharp.dll /reference:"
         C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFr
         amework\v4.0\Microsoft.CSharp.dll" /reference:"C:\Program Files (x86)\
         Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\mscorlib.d
         ll" /reference:C:\Users\Administrator\Downloads\NopCommerceWeb\Librari
         es\Nop.Core\bin\Release\Nop.Core.dll /reference:C:\Users\Administrator
         \Downloads\NopCommerceWeb\Libraries\Nop.Data\bin\Release\Nop.Data.dll
         /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Fram
         ework\.NETFramework\v4.0\System.Core.dll" /reference:"C:\Program Files
          (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\Sys
         tem.Data.DataSetExtensions.dll" /reference:"C:\Program Files (x86)\Ref
         erence Assemblies\Microsoft\Framework\.NETFramework\v4.0\System.Data.d
         ll" /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\
         Framework\.NETFramework\v4.0\System.dll" /reference:"C:\Program Files
         (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\Syst
         em.Drawing.dll" /reference:"C:\Program Files (x86)\Reference Assemblie
         s\Microsoft\Framework\.NETFramework\v4.0\System.EnterpriseServices.dll
         " /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Fr
         amework\.NETFramework\v4.0\System.Web.dll" /reference:C:\Users\Adminis
         trator\Downloads\NopCommerceWeb\packages\aspnetmvc\System.Web.Mvc.dll
         /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Fram
         ework\.NETFramework\v4.0\System.Web.Services.dll" /reference:"C:\Progr
         am Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\
         v4.0\System.Xml.dll" /reference:"C:\Program Files (x86)\Reference Asse
         mblies\Microsoft\Framework\.NETFramework\v4.0\System.Xml.Linq.dll"
     2>Project "C:\Users\Administrator\Downloads\NopCommerceWeb\NopCommerce.sln
       " (2) is building "C:\Users\Administrator\Downloads\NopCommerceWeb\Tests
       \Nop.Data.Tests\Nop.Data.Tests.csproj" (11) on node 7 (default targets).
    11>GenerateTargetFrameworkMonikerAttribute:
       Skipping target "GenerateTargetFrameworkMonikerAttribute" because all ou
       tput files are up-to-date with respect to the input files.
       CoreCompile:
       Skipping target "CoreCompile" because all output files are up-to-date wi
       th respect to the input files.
       _CopyAppConfigFile:
       Skipping target "_CopyAppConfigFile" because all output files are up-to-
       date with respect to the input files.
       CopyFilesToOutputDirectory:
         Nop.Data.Tests -> C:\Users\Administrator\Downloads\NopCommerceWeb\Test
         s\Nop.Data.Tests\bin\Release\Nop.Data.Tests.dll
       PostBuildEvent:
         if not exist "C:\Users\Administrator\Downloads\NopCommerceWeb\Tests\No
         p.Data.Tests\bin\Release\x86" md "C:\Users\Administrator\Downloads\Nop
         CommerceWeb\Tests\Nop.Data.Tests\bin\Release\x86"
         xcopy /s /y "C:\Users\Administrator\Downloads\NopCommerceWeb\packages\
         SqlServerCompact.4.0.8482.1\NativeBinaries\x86\*.*" "C:\Users\Administ
         rator\Downloads\NopCommerceWeb\Tests\Nop.Data.Tests\bin\Release\x86"
         if not exist "C:\Users\Administrator\Downloads\NopCommerceWeb\Tests\No
         p.Data.Tests\bin\Release\amd64" md "C:\Users\Administrator\Downloads\N
         opCommerceWeb\Tests\Nop.Data.Tests\bin\Release\amd64"
         xcopy /s /y "C:\Users\Administrator\Downloads\NopCommerceWeb\packages\
         SqlServerCompact.4.0.8482.1\NativeBinaries\amd64\*.*" "C:\Users\Admini
         strator\Downloads\NopCommerceWeb\Tests\Nop.Data.Tests\bin\Release\amd6
         4"
             if not exist "C:\Users\Administrator\Downloads\NopCommerceWeb\Test
         s\Nop.Data.Tests\bin\Release\x86" md "C:\Users\Administrator\Downloads
         \NopCommerceWeb\Tests\Nop.Data.Tests\bin\Release\x86"
             xcopy /s /y "C:\Users\Administrator\Downloads\NopCommerceWeb\packa
         ges\SqlServerCompact.4.0.8852.1\NativeBinaries\x86\*.*" "C:\Users\Admi
         nistrator\Downloads\NopCommerceWeb\Tests\Nop.Data.Tests\bin\Release\x8
         6"
             if not exist "C:\Users\Administrator\Downloads\NopCommerceWeb\Test
         s\Nop.Data.Tests\bin\Release\amd64" md "C:\Users\Administrator\Downloa
         ds\NopCommerceWeb\Tests\Nop.Data.Tests\bin\Release\amd64"
             xcopy /s /y "C:\Users\Administrator\Downloads\NopCommerceWeb\packa
         ges\SqlServerCompact.4.0.8852.1\NativeBinaries\amd64\*.*" "C:\Users\Ad
         ministrator\Downloads\NopCommerceWeb\Tests\Nop.Data.Tests\bin\Release\
         amd64"
    10>SGEN : error : Could not load file or assembly 'file:///C:\Users\Adminis
       trator\Downloads\NopCommerceWeb\packages\EPPlus.3.0.0.2\lib\net20\EPPlus
       .dll' or one of its dependencies. Operation is not supported. (Exception
        from HRESULT: 0x80131515) [C:\Users\Administrator\Downloads\NopCommerce
       Web\Libraries\Nop.Services\Nop.Services.csproj]
           - An attempt was made to load an assembly from a network location wh
         ich would have caused the assembly to be sandboxed in previous version
         s of the .NET Framework. This release of the .NET Framework does not e
         nable CAS policy by default, so this load may be dangerous. If this lo
         ad is not intended to sandbox the assembly, please enable the loadFrom
         RemoteSources switch. See http://go.microsoft.com/fwlink/?LinkId=15556
         9 for more information.
    10>Done Building Project "C:\Users\Administrator\Downloads\NopCommerceWeb\L
       ibraries\Nop.Services\Nop.Services.csproj" (default targets) -- FAILED.
    11>PostBuildEvent:
         0 File(s) copied
         File not found - *.*
         0 File(s) copied
         File not found - *.*
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\x86\sqlceca40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\x86\sqlcecompact40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\x86\sqlceer40EN.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\x86\sqlceme40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\x86\sqlceqp40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\x86\sqlcese40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\x86\Microsoft.VC90.CRT\Microsoft.VC90.CR
         T.manifest
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\x86\Microsoft.VC90.CRT\msvcr90.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\x86\Microsoft.VC90.CRT\README_ENU.txt
         9 File(s) copied
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\amd64\sqlceca40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\amd64\sqlcecompact40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\amd64\sqlceer40EN.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\amd64\sqlceme40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\amd64\sqlceqp40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\amd64\sqlcese40.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\amd64\Microsoft.VC90.CRT\Microsoft.VC90.
         CRT.manifest
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\amd64\Microsoft.VC90.CRT\msvcr90.dll
         C:\Users\Administrator\Downloads\NopCommerceWeb\packages\SqlServerComp
         act.4.0.8852.1\NativeBinaries\amd64\Microsoft.VC90.CRT\README_ENU.txt
         9 File(s) copied
    11>Done Building Project "C:\Users\Administrator\Downloads\NopCommerceWeb\T
       ests\Nop.Data.Tests\Nop.Data.Tests.csproj" (default targets).
     2>Done Building Project "C:\Users\Administrator\Downloads\NopCommerceWeb\N
       opCommerce.sln" (default targets) -- FAILED.
     1>Done Building Project "C:\Users\Administrator\Downloads\NopCommerceWeb\b
       uild\nop.proj" (default targets) -- FAILED.

Build FAILED.

       "C:\Users\Administrator\Downloads\NopCommerceWeb\build\nop.proj" (defaul
       t target) (1) ->
       "C:\Users\Administrator\Downloads\NopCommerceWeb\NopCommerce.sln" (defau
       lt target) (2) ->
       "C:\Users\Administrator\Downloads\NopCommerceWeb\Libraries\Nop.Services\
       Nop.Services.csproj" (default target) (10) ->
       (GenerateSerializationAssemblies target) ->
         SGEN : error : Could not load file or assembly 'file:///C:\Users\Admin
       istrator\Downloads\NopCommerceWeb\packages\EPPlus.3.0.0.2\lib\net20\EPPl
       us.dll' or one of its dependencies. Operation is not supported. (Excepti
       on from HRESULT: 0x80131515) [C:\Users\Administrator\Downloads\NopCommer
       ceWeb\Libraries\Nop.Services\Nop.Services.csproj]

    0 Warning(s)
    1 Error(s)

Time Elapsed 00:00:01.27
Press any key to continue . . .
12 years ago
So when I go unblock all of the dlls I can find everywhere, guess what I can now get the two Bat files to work.

Guys thanks for the advice.  Developers, you need to rectify this! It is just not acceptable.
11 years ago
I am having the same issue on running the Prepate.bat...

Build started 10/23/2012 5:46:45 AM.
     1>Project "C:\Users\ztumamak\Desktop\nopCommerce_2.65_Source\build\nop.proj" on node 1 (default targets).
         Building Everything
     1>Project "C:\Users\ztumamak\Desktop\nopCommerce_2.65_Source\build\nop.proj" (1) is building "C:\Users\ztumamak\Desktop\nopCommerce_2.65_Source\NopCommerce.sln" (2) on node 1 (default targets).
     2>C:\Users\ztumamak\Desktop\nopCommerce_2.65_Source\NopCommerce.sln.metaproj : error MSB4126: The specified solution configuration "Release|BPC" is invalid. Please specify a valid solution configuration using the Configuration and Platform properties (e.g. MSBuild.exe Solution.sln /p:Configuration=Debug /p:Platform="Any CPU") or leave those properties blank to use the default solution configuration.
     2>Done Building Project "C:\Users\ztumamak\Desktop\nopCommerce_2.65_Source\NopCommerce.sln" (default targets) -- FAILED.
     1>Done Building Project "C:\Users\ztumamak\Desktop\nopCommerce_2.65_Source\build\nop.proj" (default targets) -- FAILED.

Build FAILED.

       "C:\Users\ztumamak\Desktop\nopCommerce_2.65_Source\build\nop.proj" (default target) (1) ->
       "C:\Users\ztumamak\Desktop\nopCommerce_2.65_Source\NopCommerce.sln" (default target) (2) ->
       (ValidateSolutionConfiguration target) ->
         C:\Users\ztumamak\Desktop\nopCommerce_2.65_Source\NopCommerce.sln.metaproj : error MSB4126: The specified solution configuration "Release|BPC" is invalid. Please specify a valid solution configuration using the Configuration and Platform properties (e.g. MSBuild.exe Solution.sln /p:Configuration=Debug /p:Platform="Any CPU") or leave those properties blank to use the default solution configuration.

    0 Warning(s)
    1 Error(s)

Time Elapsed 00:00:00.26


I edited the Australia Post plugin into its new gateway URL and the new required parameters in that API... So by that, I need to create a deploy-able project to put it in my webserver..
11 years ago
See response to your other post.
Please don't double post.
11 years ago
how do i run prepare.ba
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.