-
Notifications
You must be signed in to change notification settings - Fork 199
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
Failed compilation - "No such file or directory @ rb_sysopen" #33
Comments
Hi Giles, Thanks for reporting. It's me who used Based on the output it seems not like a big problem. The error happened at the very last step when the compiler is copying the final product from Did you use |
Hi Minqi, Thanks for the reply. After creating the output directory and rerunning, the situation has improved. It now compiles and I get an output file. However, when running this app (it's a web server that uses couchbase) I get an error:
This file is in the node_modules/couchbase tree. How do I package this in the output, or point to it as an external file? The readme does not make this clear. I also made a cut down version of the app that doesn't use couchbase. This compiled and ran, but when trying to access the web index.html page, it can't find this. I guess it's going to be the same problem - how do I package the html file in the executable, or access it externally? Thanks, |
@gillez Thanks for the feedback. For the first problem, it's related to #29, #25 and #27 and has been fixed yet not released. Native modules are starting to work on the master branch, if you are urgent you could clone the repo and run For the second problem, I am not quite sure what you are referring to that is missing. Could you give me more details? What do you mean by "it can't find this"? Thank you. |
Hi Minqi, Sorry for the lack of details on the second issue. Here's some more info:
This works perfectly when starting the server directly through node. However, when running the nodec compiled app, this call gives the following error:
I guess this is because the "__dirname" variable does not have a valid value? What should I use here? I have also compiled my app using pkg which is working. In that case I have to list my html files (and other files for the website, such as JS and images) as assets, which are then packaged into the single-file executable. There are no code changes and my website is delivered correctly. Do I need to do a similar thing with node compiler? As an aside, the only files which are not packaged into the single-file with pkg are native modules such as couchbase_impl.node. Those need to be supplied separately, in the same directory as the pkg output. I have tried the same thing with the nodec output, thinking it would solve my first issue but it didn't help. Thanks, |
Hi Minqi, Do you have any more info on my second issue above? I'd like to know how to package my html/js files for the client website inside the node app, or whether this should be done another way. I'm sure it's just me doing something silly or not specifying the assets or something. Thanks, |
Hi Giles, Sorry for the delay. I've been working busily towards nodec v1.0 recently. Regarding Therefore this is either a bug in nodec, or the code Minqi |
Thanks Minqi, Actually I think that explains it. The public directory is actually a sub directory of the parent of my app. My real code is more like I'll update this thread to let you know when I've tried it. Cheers, |
Hi,
I'm trying to compile my node app on MacOS v10.11.6. It fails with the following error:
I don't use ruby or rb_sysopen directly in my code, but I guess it's possible that one of the included npm modules do (although a grep in the node_modules directory for rb_sysopen drew a blank).
I am using the following version:
Node.js Compiler (nodec) v0.9.6 (runtime 7.10.0)
Can anyone help with this?
Thanks,
Giles
The text was updated successfully, but these errors were encountered: