I am using 32bit node.js . I want to know if edge.js creates the .NET executable also in 32 bit or not. The OS is 64 bit windows. This is specific to understand edge.js native executable not Node.js process.
Asked
Active
Viewed 121 times
0
-
Please add addtional information on how you build. – OutOfBound Oct 11 '17 at 13:12
-
1Possible duplicate of [How do I determine if a .NET application is 32 or 64 bit?](https://stackoverflow.com/questions/3782191/how-do-i-determine-if-a-net-application-is-32-or-64-bit) – Pac0 Oct 11 '17 at 14:00
-
@Pac0 I don't think this is same as what you have linked to. – SwadX Oct 12 '17 at 06:21
-
The process I am following is as below. I first created a DLL of my C# code using the .NET csc compiler . I used the /platform:x86 compiler option while creating the DLL. Now I am using this DLL in my edge.js call as shown var getModel_info = edge.func({ assemblyFile:'../Test/DLLs/test.dll', typeName: 'com.xxx.test.Startup', methodName: 'Invoke' }); – SwadX Oct 12 '17 at 06:21
-
Now I am trying to run this thru "node app.js" command. the node process is 32 bit as shown in task manager . but my question is about the C# executable that edge.js creates is that 32 bit or not , how can I check ? – SwadX Oct 12 '17 at 06:29
-
1As I understand your question from the few details you give here, and also here https://github.com/tjanczuk/edge/issues/596 , you are simply unsure about the 32 vs 64 bits version for your generated dll. At least, with the general solution I linked, you can check for yourself if the produced dll is actually marked for 32bits or 64bits. This should give more insight, and that would be a first preliminary action you should take IMHO. The tool is called `CorFlags.exe` and in my machine is located in `/c/Program Files (x86)/Microsoft SDKs/Windows/v8.1A/bin/NETFX 4.5.1 Tools`, – Pac0 Oct 12 '17 at 07:10
-
For the other generated dll, you can also try `dumpbin` , see https://stackoverflow.com/questions/480696/how-to-find-if-a-native-dll-file-is-compiled-as-x64-or-x86?noredirect=1&lq=1 – Pac0 Oct 12 '17 at 07:12
-
I used corflags.exe and the DLL is 32 bit as expected as I had compiled it with x86 option. But how do I know if the edge.js executable that references this DLL is also 32 bit or not. Microsoft (R) .NET Framework CorFlags Conversion Tool. Version 3.5.30729.1 Copyright (c) Microsoft Corporation. All rights reserved. Version : v4.0.30319 CLR Header: 2.5 PE : PE32 CorFlags : 3 ILONLY : 1 32BIT : 1 Signed : 0 – SwadX Oct 12 '17 at 09:30
-
this CorFlags you've just posted result indicates a 32bits .NET executable (`32BIT : 1`) – Pac0 Oct 12 '17 at 10:06
-
with help from a colleague I found that to understand or even force Edge to use 32 or 64 bit , we can set the environment variables EDGE_NATIVE and EDGE_DEBUG . We can set EDGE_NATIVE to the path of the 32 bit or 64 bit native like this set EDGE_NATIVE=../edge/lib/native/win32/ia32/8.2.1/edge_nativeclr.node and setting EDGE_DEBUG=1 helps in understanding more. – SwadX Oct 17 '17 at 08:41