-
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
Can we resurrect node-packer to get it working with latest Node.js versions? #145
Comments
@pmq20 - I thought more about it and I feel that it can also be a viable option to pass on the knowledge to the community so that someone from the community can carry forward this great tool. Thoughts? |
Hello @pmq20! I remember you mentioning on the Node 10 PR about working on upgrade to Node 12. Just wanted to follow up on the same. Do you have an approx time frame in mind for that? Would very much appreciate your response on this. :-) |
Hey @pmq20! I had been looking forward to getting the Node12 support after your comment on the Node10 PR. But I just noticed in the about section that this repository has stopped maintenance. Does that mean this project is officially dead? I hope NOT. If yes, it is very unfortunate. There are no active forks also. There are a few options available to generate Node.js binary like pkg, nexe etc. But none of them close to the quality of the binary created by node-packer, without any custom coding being required. Will it be possible for you to create a how to doc for me to try and take this forward? This will be a massive help. Eagerly looking forward to your response. |
@saurabh-deep Thank you for the feedback! Your feedback brings a lot of encouragement to me. I really appreciate it. I previously put up the stop-maintenance notice because there seems to be no time to maintain it for me personally due to my weekday work. But it does appear that the project is still relevant and many people want to use it, so I should continue maintaining it. Hence I have deleted that notice. I also do agree that community is the key to keep the project alive, because one person's time is too limited. Please feel free to ask me any technical questions about its implementation. Everybody's participation is greatly welcome and appreciated! Let me start resurrecting it this weekend (because of work I can only work on it in the weekends). I think the first thing to do is to upgrade it to node.js v14. I'll let you know what I accomplished after this weekend. |
@pmq20 - Best news I have had in a while. 😄 v14 is great! We will also need v12 - but surely, that can come later. Please do let me know if I can help in any way. These are some the node-packer positives which aren't to be found in any other packaging solution -
|
@saurabh-deep Thanks for the compliments. I am really glad that people actually love this tool. I tried upgrading to 14.8.0 this weekend and it was easier than I thought. I have reviewed all the hacks, and only kept the essential ones. They were gathered in this commit: a4ab86d You can see that there's not too many essential hacks, so it is promising that we can maintain the project in the long run without too much burden. Of course the heavy lifting still happens in libsquash, but that part is easier to maintain (just copy and paste). But I have not actually tested if the old hacks still work for the new Node.js. Let me do that next week with the goal of setting up a CI to check the quality of the tool. Also I plan to make CI build and release |
This is wonderful @pmq20. I will give it a spin once the latest
Second, lets say I want to build nodec for the current Node.js LTE version (v12.18.3). What should be my steps?
Also, I wanted to point out that Python 2 is End of Life now. Can we upgrade to Python 3 now somehow or do you think it will cause an issue? I also noticed that you added cross-compilation to the README.md. That is a very welcome change. I haven't tried it yet but will certainly do once you think it is ready for a test drive. Once again, many thanks for hard work and bringing this project to life! 🙇♂️ I will let others in the community know about this progress so that more people can banefit from your hard work and stop compromising on features (like Mac OS code-signing) which do not work correctly using any other tool. Please let me know about my questions on building a new nodec for Node.js v12.18.3 and I will try and contribute on that as soon as my schedule allows. |
@saurabh-deep Yeah, as a user one should probably wait a little since the current changes are WIP; unless one wish to try out the bleeding edge and contribute to the WIP development, which is greatly welcome. Yeah that is pretty much the steps. To compile all the new stuff into a new version of Thanks for the info on Python 3. I imagine it might already works, as I cannot recall any special usage of python 2 specifically. To support both Node 12 and Node 14, I plan to maintain two I wish I had more time to work on it. Let me keep working on it the next weekend. |
@pmq20 - I will be compiling my binary with |
@saurabh-deep Last time I tried, There was some errors when running that needs to be fixed. I plan to use some coming weekends to fix them. Also, if possible, could you share the project that you were trying to pack, so that I can use it as a reference to test the packing process? Thank you again for your feedback! |
@pmq20 - My project is in a private (company-owned) GitLab repository, which I am not authorised to share, unfortunately. Apologies for this! But I will setup a similar public project on GitHub that you can use as a reference. I should be able to set this up over the weekend. For the errors that you mentioned, please let me know whenever you get a chance to work on them. I will be more than happy to test and share feedback with you. One request though. Can we please start with To tell you the truth, we are currently running And yes, just so you know, once we have finalised this first new build, I will be sharing this important update with the rest of the community who have to use other inferior packing tools today because there is no option. I know for a fact that those people will love to use node-packer, as I do. 🥰 |
@saurabh-deep Thanks for the reply. No problems. I'll work on |
Bat:
Log:
|
Hi @pmq20 - Apologies for the delay due to some health issues in the past couple of weeks. I have now set up this test CLI project which you can use to test binary compilation. I haven't been able to set up GitHub Action for this as of yet, but I tried the latest node-packer code to build the binary on my local Mac and Windows, and in an ubuntu docker container for Linux - all 3 using the Ruby command. Till now, all 3 compilations are failing. Linux and Mac have the same error, while Windows shows a different one. Please note that the project is fully compatible with Node12 (lts) and may not be fully compatible with Node14(current), but it should still compile. Also, Yarn is used with the project instead of NPM. I hope it doesn't cause any issues for you. I will try to set up GH Actions for the test Node project ASAP, but since I don't have much experience on GH Actions - so it will take time. If you want to give it a go, please let me know. I will very glad to share the access for that project with you. Now the errors that I have been facing so far - First of all, the compilation doesn't start and fail if the current working directory is set to the test Node project (node-cli-test). To be able to start the compilation, I am forced to execute the Ruby command from the node-packer directory, which is going to be a problem in CI. Earlier version of node-packer allowed us to execute the ruby command from the node project itself. It is important for the Ruby command to be executable from the node project itself. As of now, I receive the following error when I execute the following command from the test Node project - Working directory: Alternatively, when I execute the Ruby command from the node-packer directory, it starts the compilation but fails with the following error, both for Mac (OSX 10.14.6) and Linux (Ubuntu). Same errors are encountered if the pre-compiled nodec binary is used for compilation. Can I also take this opportunity to request you to downgrade the MacOS version from macos-10.15 to macos-10.14 in the GH Action workflow? The nodec binary created from macos-10.15 is not compatible with 10.14 and I am not in a position to upgrade as of this moment. Please let me know if you have any concerns related to this. Working directory: |
Hello @pmq20 - I forgot to include the Windows error that I am receiving when building from node-packer source using Ruby command. For Linux and Mac OS, I shared the same in my previous message. Windows error: Creating library out\Release\mkcodecache.lib and object out\Release\mkcodecache.exp |
@YYago @saurabh-deep Thanks for reporting! The |
Is it possible to downgrade macos-10.15 to macos-10.14 in the GH Action workflow? I read GH's document and it appears that only 10.15 was provided. Maybe 10.14 would be there if I just declare EDITED: |
@saurabh-deep Also thank you for setting up the repository! I'll use it soon. I was too busy with some other responsibilities in my life recently. |
Thanks for checking this @pmq20. I also verified and it seems they have removed
Please let me know if you need write access to this repository or the two dependency package repositories. These have created specifically for testing binary creation, so there are at your disposal - whichever way you want to use them. And we all have other responsibilities in our lives, so don't even worry about node-packer at all. Personal life comes first. I hope everything is fine. 🤞
That's fine and expected @pmq20. Please take your time. In your absence we tried to look into the macOS/Linux issue and also noticed a few lines of code missing in the Node.js hacks when compared with the old working versions. We made a few small changes and the macOS compilation actually worked after that. But the execution is very buggy. The executable doesn't seem to be able to read the standard input when using |
Hi @pmq20 ! Hope you are doing well. Just wanted to let you know that I will be available to help you over this weekend, if you need. We have been trying to make changes in the node-packer hacks in |
Hi @pmq20 - I wanted to ping here to check if everything is fine with you and if it is going to be possible for you to look into the issues reported above with the latest node-packer (lts and current)? |
Just want to share that with commit On the other hand, I haven't found a rev of this repo which works for Node.js v14 so I'm also waiting for that. |
Thanks for sharing @NexZhu. We are in need of Node v12 only at the moment. We can wait for Node v14 for a bit longer. I will it a go using the commit id that you mentioned and share the updates here. |
I'm also getting the "unresolved external symbol __imp_PathMatchSpecA referenced in function EncloseIOFindFirstFileHelper" error. Any news on this yet? |
Hello @pmq20 - Happy New Year! I hope you have had time to sort out the stuff you were going through previously. I am very excited as I saw a commit from you in this repo over the weekend (after a few months) -- Read me only 😃 . Do you think you will be able to spend some time on the node-packer now to resolve the issues we are facing with Node 12 and 14? If only, any of us knew enough C, we would have been able to help you. 😸 |
@saurabh-deep Sorry but I do not think I have the time to maintain the project. I am willing to add anybody who wishes to maintain the project as a collaborator of the repo. |
@pmq20 This is sad and heart-breaking, but understandable. There was no other tool that came anywhere close to node-packer. It is such a shame that I don't have what it takes to maintain this project, as it requires comprehensive C expertise. Do you think we can get on a call to discuss the issues and the options? |
this project is realy needs a second or a third life... I decided to try it again on ubuntu 20.04 and a test http script was succesful on https://github.com/slee047/node-packer/tree/TestSeries12 branch which it based on 12.13.0 nodejs ... i will try to compile my main project with this version and will post results, before i was stuck to 10.15.3 version |
Well i tried to mentioned above fork/branch with my project and it is not realy working. i hope node-packer can be resurrected, so far i can not find any alternative which would work like this, but it has it down sides (unpredictible Segmentation Faults) |
Thank you @Asp3ctus for sharing your findings. Like I said earlier, it is heart-breaking to see node-packer come to a close. I don't know anyone with the kind of C knowledge that seems to be required here, or I would ask them for help. The way things stand right now, it is completely dependent on @pmq20. I wish he had some time to look into node-packer, only once in a while. If the current issues could be resolved, it would only need some work again only when Node 16 is out there. Till then we could easily live with these versions. |
@Asp3ctus Actually i think i resolved the sockets and file problem on Ubuntu 16.04 and 18.04. The 20.04 may work which i have not tested. My modified version is nodejs v12.18.2. The way of fix it i think can be apply to all new v12.x of nodejs. @pmq20 The method to solve sockets and file problem is the virtual fd conflict with system fd, here is code hack it, it may help you get a clue
|
@roytan883 - That's awesome to know that you have been able to identify the problem. Can you please share where the updated code is so that I can also give it a go? Thanks much! |
@roytan883 / @Asp3ctus - Can you please help me with the updated code, folks - a version with the above mentioned changes? Looking forward to test these on Mac OS and Windows too. |
@saurabh-deep - Hi, i have not yet tried to folow @roytan883 instructions yet. I will actualy try it next week, |
Well i tried to apply changes, mentioned above, but the build resulting test app did not start the execution of js code, so i was unsuccessful with this changes |
Hey @pmq20! Hope you are doing well.
Is there a possibility of resurrecting this project? It has been a very popular project with some forks even managing to get this working till Node10. But it seems we are at the end of the road as I am not aware if anyone has had any success with Node12.
There are not many other options available to create Node.js binary and all of them have issues with the OS X signing/notarization and the binaries are too big.
I understand you being busy with your current job and projects. Still wanted to check if it was a possibility to bring this project back to life.
Many thanks! Cheers!
The text was updated successfully, but these errors were encountered: