pmed / v8-nuget

NuGet package for V8 JavaScript Engine
93 stars 27 forks source link

"Cannot open file v8.lib" #3

Closed fatcerberus closed 6 years ago

fatcerberus commented 7 years ago

Just installed v8-v140_xp-x64 in my project, didn't change any project settings, and now get the above error on build.

fatcerberus commented 7 years ago

This happens for the x86 package too.

fatcerberus commented 7 years ago

I figured it out, it looks like the v140 and v140_xp packages are swapped. My project is using the XP toolset and after I installed v8-v140-x64, it linked properly.

pmed commented 7 years ago

Hi @fatcerberus

That's strange. I've just checked V8 packages with my v8pp project on Visual Studio 2013 and 2015 versions, x86 and x64 targets, both for xp and non-xp toolsets. And all these combinations work as intended:

I've done all the checks in a clean solution, with no other packages installed before.

When the required V8 package is missing, I get an error "Cannot open include file: 'v8.h': No such file or directory" instead of the error about absent v8.lib.

fatcerberus commented 7 years ago

Huh. Something must be screwed up with my solution file or MSVC installation then. Last night I had another problem too: It couldn't find the include files. I finally had to resort to copying the files out of the packages directory and referencing them manually.

I'll see what happens with a fresh solution.

fatcerberus commented 7 years ago

Something must be wrong on my end - regardless of which package I install, it fails at compile time with "cannot open include file v8.h". Not sure what's going on, but the V8 packages themselves doesn't seem to be at fault.

I'll report back if I find out anything else.

maliming commented 7 years ago

i have the same problem WIN10 VS2015 XP toolset : can't open v8.h

padjon commented 7 years ago

I have the same issue: can't open v8.h Win10 VS15 v140 Toolset

padjon commented 7 years ago

Some additional input:

Adding the include folder manually (packages\v8-v140-x86.5.6.326.55\include in my case) fixes it for me. no dependencies or anything else to add.

pmed commented 7 years ago

This issue is still unreproducible on my side, both with existing and fresh project.

Please check that you have installed the proper version of package, depending on the Platform and Toolset version used, as described in a comment above https://github.com/pmed/v8-nuget/issues/3#issuecomment-261187239

padjon commented 7 years ago

I did, added even all packages at one time for testing purposes. My current setup is to have the v140 x86 installed and manually add the include folder. Everything else works then by no manual modifications. Libs are copied correctly.

fatcerberus commented 7 years ago

Same issue with MSVC 2017: Imgur

No modifications were made to the project after installing the packages, this was immediately after installing them and attempting to build.

padjon commented 7 years ago

I noticed, the import issue happens for me because of other property sheets which defined additional include paths without the option "inherit from parent o project defaults". if i remove these sheets or activate the option, the includes are recognized.

This might help for reproducing @pmed

fatcerberus commented 7 years ago

Hm, that could be the case for me then, my project uses Allegro which has its own property sheet.

pmed commented 7 years ago

Thank you, @padjon

Yes, it seems other property sheets with overriding include/library path settings may be the issue cause.