Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build for windows does not work "libplatform/libplatform.h": No such file or directory #498

Open
MinePlay96 opened this issue Jan 12, 2020 · 10 comments

Comments

@MinePlay96
Copy link

MinePlay96 commented Jan 12, 2020

hello i am currently trying to build J2V8 with node js 7.4
but i always get the error.

C:\Users\leons\Documents\GitHub\J2V8\jni\com_eclipsesource_v8_V8Impl.cpp(12): fatal error C1083: Datei (Include) kann n
icht geöffnet werden: "libplatform/libplatform.h": No such file or directory [C:\Users\leons\Documents\GitHub\J2V8\cmak
e.out\win32.x64\j2v8.vcxproj]

i am now helpless what to do.

i would also be satisfied if i would get a pre-built version for Windows x32 which contains at least node 6. (node 13 would be even better ;) )

@ahmadov
Copy link
Contributor

ahmadov commented Feb 7, 2020

Hi @MinePlay96,

Currently, The latest version of J2V8 does not support the Windows platform. see for details: #441.

Have you tried that build (https://search.maven.org/search?q=a:j2v8_win32_x86_64) from Maven central?

@rohitcelestial
Copy link

@ahmadov - I am facing the same error even on linux platform.

fatal error: libplatform/libplatform.h: No such file or directory
 #include <libplatform/libplatform.h>
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~

@ahmadov
Copy link
Contributor

ahmadov commented Mar 4, 2020

Hi @rohitcelestial
could you please try that #487 (comment)

@MinePlay96
Copy link
Author

Hi @ahmadov - i solved it by just using this Fork https://github.com/drywolf/J2V8

@rohitcelestial
Copy link

@ahmadov - Thanks, I was able to build but it seems it's only V8 (which I understand is the project) but I was looking for NodeJS operations like require etc.

final NodeJS nodeJS = NodeJS.createNodeJS();

results in UnsupportedOperationException: startNodeJS Not Supported

@ahmadov
Copy link
Contributor

ahmadov commented Mar 5, 2020

Yes, the newer version of J2V8 dropped the NodeJS support. So, you cannot use NodeJS require method but you can implement your own one. You can register a JavaCallback for your method and implement native support, see:

  1. https://github.com/eclipsesource/J2V8/blob/master/src/main/java/com/eclipsesource/v8/V8.java#L797
  2. https://github.com/eclipsesource/J2V8/blob/master/src/main/java/com/eclipsesource/v8/JavaCallback.java

@mkshiblu
Copy link

mkshiblu commented Jun 1, 2020

@MinePlay96 How did you manage the build? Which j2V8 and NodeJs versions you were able to use? I want to use a higher node version too. I am not sure what was the last version of j2v8 that supported Node.

@longwa
Copy link

longwa commented Nov 23, 2021

Following the build steps I also get this same failure on MacOS. I'm choosing the option from the interactive build menu and have followed the steps in the BUILD guide.

Is there any resolution to this problem? The fork mentioned earlier is very old now as is the published MacOS version.

@longwa
Copy link

longwa commented Nov 23, 2021

The build ends up looking for this include directory that doesn't exist:

-I/Users/along/github/J2V8/v8.out/include

I see some of the includes in:

./node/deps/v8/include
./node/deps/v8_inspector/include

But changing those in the CMake just results in compile errors.

Is MacOS x86 even a supported build anymore?

@caoccao
Copy link

caoccao commented Nov 24, 2021

Is MacOS x86 even a supported build anymore?

I don't think so. Please refer to Reduce the scope of the J2V8 project for detail.

I built a private build of v6.2.0 for Linux and Windows in this January. It wasn't a happy thing to me. So I didn't bother building the Mac OS one. You are welcome trying the private build on Linux or Windows.

If you are keen on something equivalent on Mac OS, so far the only option seems to be Javet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants