简体   繁体   English

NWJS 为不同的操作系统和不同的架构编译二进制文件

[英]NWJS compiling binary for different OS and different arch

I need help in compiling binary files from MacOS to Windows32 & Windows64 bit.我需要帮助将二进制文件从 MacOS 编译到 Windows32 和 Windows64 位。 In documentation it is written that we need to compile binary according to platform but actual options/parameters are not provided in documentation for it文档中写到我们需要根据平台编译二进制文件,但文档中没有提供实际的选项/参数

Got the parameters from nwjc --help section, tried with following but nothing works:nwjc --help部分获取参数,尝试以下但没有任何效果:

nwjc --target-os win32 --target-arch ia32 nwapp/main.js nwapp/main.bin
nwjc --target-os win32 --target-arch x86_64 nwapp/main.js nwapp/main.bin
nwjc --target-os win32 --target-arch x64 nwapp/main.js nwapp/main.bin

By default, the binary compiled on MacOS is running on 64 bit windows without any target parameters.默认情况下,在 MacOS 上编译的二进制文件在 64 位 windows 上运行,没有任何目标参数。 Can you give me the parameters and possible values for compiling for Windows32 & Windows 64 from MacOS?你能给我从 MacOS 编译 Windows32 和 Windows 64 的参数和可能的值吗?

I have got the answer from nwjs gitter group .我从nwjs gitter group得到了答案。 The answer is:答案是:

If you want to compile JS files to v8 binary files for a target platform, let's suppose Windows 32 bit, then you need to compile them on the target platform only.如果要将JS文件编译为目标平台的v8二进制文件,假设Windows 32位,则只需在目标平台上编译即可。 You cannot compile binaries for Windows 32 from a different OS (in my case I was trying with MacOS)您无法从不同的操作系统编译 Windows 32 的二进制文件(在我的情况下,我正在尝试使用 MacOS)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 nwjs - 在二进制文件上调用 function - nwjs - call function on binary file 用于在不同目录中编译的 TypeScript API - TypeScript API for compiling in a different directory 用不同的数据编译Jade部分 - Compiling Jade partial with different data 同一二进制文件产生不同的md5 - Same binary produces different md5 读取图像的二进制代码以将其写入不同的文件 - Read binary code of image to write it into a different file 尝试运行电子项目时的不同编译版本 - Different compiling version while trying to run an electron project 在node-gyp binding.gyp文件中,如何根据系统arch(32位,64位)包含不同的库文件) - In node-gyp binding.gyp file, how to include different library files based on the system arch (32 bit, 64bit)) inotify@1.4.1 不支持的平台:想要 {“os”:“linux”,“arch”:“any”} - Unsupported platform for inotify@1.4.1: wanted {“os”:“linux”,“arch”:“any”} os.loadavg()返回的值与正常运行时间不同 - os.loadavg() returns different values than uptime selenium 浏览器驱动程序(Chrome、Firefox、IE、Edge 等)是针对 node.js 编译的 OS 架构还是实际 PC 处理器架构或已安装的 OS 架构? - Are selenium browser drivers (Chrome, Firefox, IE, Edge, etc) for node.js compiled OS arch or for actual PC processor arch or installed OS arch?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM