Mahdi-zarei / nekoray

Qt based cross-platform GUI proxy configuration manager (backend: sing-box)
GNU General Public License v3.0
255 stars 17 forks source link

Is there any chance to compile a Mac version? #16

Closed klacee closed 1 week ago

klacee commented 1 month ago

Is there any chance to compile a Mac version?

Mahdi-zarei commented 1 month ago

Most likely yes, I believe the reason that the mac version was discontinued is that handling tun interfaces was a challenge. Since we now use the sing-box's tun handler, i assume it shouldn't be a problem to compile a mac version, I will try to do it and see if it works.

AkramiPro commented 1 month ago

is it possible to also have win7 version? i think main repo delete win7 support because of QT compatibility.

Mahdi-zarei commented 1 month ago

is it possible to also have win7 version? i think main repo delete win7 support because of QT compatibility.

I guess not, I believe sing-box has limitations on windows 7 and older, so I doubt compiling for windows 7 would be of much help.

Rosabis commented 1 month ago

is it possible to also have win7 version? i think main repo delete win7 support because of QT compatibility.

I guess not, I believe sing-box has limitations on windows 7 and older, so I doubt compiling for windows 7 would be of much help.

Well, I recently tried to use QT5 to compile nekoray for Windows 7 without modifying the source code. It works normally except that TUN mode cannot be used.

xchacha20-poly1305 commented 4 weeks ago

Sing-tun can be used in windows7. Just use go 1.20 and gvisor stack.

Rosabis commented 4 weeks ago

Sing-tun can be used in windows7. Just use go 1.20 and gvisor stack.

I tried to change the go version to 1.20, but the build still cannot use tun mode. Do I need to use an older version of gvisor to build?

papampi commented 3 weeks ago

+1

Mahdi-zarei commented 3 weeks ago

Sing-tun can be used in windows7. Just use go 1.20 and gvisor stack.

It also seems that an older version of Qt should be used (which has memory related bugs it appears). I guess it's best to wait and see if there is any significant need for the old build.

amirhakimnejad commented 2 weeks ago

Just tested version 4.0.7, 4.0.8 on MacOs 14.5 amd. Works well, thank you. Tested with VLESS ws and reality and VMESS and trojan dns, system proxy mode. Lets me know if you need something specific tested.

AkramiPro commented 2 weeks ago

Just tested version 4.0.7, 4.0.8 on MacOs 14.5 amd. Works well, thank you. Tested with VLESS ws and reality and VMESS and trojan dns, system proxy mode. Lets me know if you need something specific tested.

can you please test Tun Mode ? image

amirhakimnejad commented 2 weeks ago

Just tested version 4.0.7, 4.0.8 on MacOs 14.5 amd. Works well, thank you. Tested with VLESS ws and reality and VMESS and trojan dns, system proxy mode. Lets me know if you need something specific tested.

can you please test Tun Mode ? image

It turns off right after I try to turn it on, but there are no trace logs. Although system proxy mode works just like tun mode in this version. It tunnels the whole system

Mahdi-zarei commented 2 weeks ago

Just tested version 4.0.7, 4.0.8 on MacOs 14.5 amd. Works well, thank you. Tested with VLESS ws and reality and VMESS and trojan dns, system proxy mode. Lets me know if you need something specific tested.

can you please test Tun Mode ? image

It turns off right after I try to turn it on, but there are no trace logs. Although system proxy mode works just like tun mode in this version. It tunnels the whole system

That's a bit weird that the system proxy in macOS tunnels the whole device. Can you change Tun stack to gvisor and see if it works? If I remember correctly there are problems with the darwin platform when using system stack.

amirhakimnejad commented 2 weeks ago

Just tested version 4.0.7, 4.0.8 on MacOs 14.5 amd. Works well, thank you. Tested with VLESS ws and reality and VMESS and trojan dns, system proxy mode. Lets me know if you need something specific tested.

can you please test Tun Mode ? image

It turns off right after I try to turn it on, but there are no trace logs. Although system proxy mode works just like tun mode in this version. It tunnels the whole system

That's a bit weird that the system proxy in macOS tunnels the whole device. Can you change Tun stack to gvisor and see if it works? If I remember correctly there are problems with the darwin platform when using system stack.

No difference. Although I managed to keep tun mode on by opening with sudo manually using this: sudo /Applications/nekoray.app/Contents/MacOS/nekoray Now shows this error: start service: initialize inbound/tun[tun-in]: configure tun interface: bad tun name: nekoray-tun

Rosabis commented 2 weeks ago

Sing-tun can be used in windows7. Just use go 1.20 and gvisor stack.

It also seems that an older version of Qt should be used (which has memory related bugs it appears). I guess it's best to wait and see if there is any significant need for the old build.

Maybe you can use some patches to make QT 6.5 works on Windows 7. https://forum.qt.io/topic/133002/qt-creator-6-0-1-and-qt-6-2-2-running-on-windows-7/

Mahdi-zarei commented 2 weeks ago

Just tested version 4.0.7, 4.0.8 on MacOs 14.5 amd. Works well, thank you. Tested with VLESS ws and reality and VMESS and trojan dns, system proxy mode. Lets me know if you need something specific tested.

can you please test Tun Mode ? image

It turns off right after I try to turn it on, but there are no trace logs. Although system proxy mode works just like tun mode in this version. It tunnels the whole system

That's a bit weird that the system proxy in macOS tunnels the whole device. Can you change Tun stack to gvisor and see if it works? If I remember correctly there are problems with the darwin platform when using system stack.

No difference. Although I managed to keep tun mode on by opening with sudo manually using this: sudo /Applications/nekoray.app/Contents/MacOS/nekoray Now shows this error: start service: initialize inbound/tun[tun-in]: configure tun interface: bad tun name: nekoray-tun

This clarifies things, I assume we could get it to work on the next release, but there is no rush for now since system proxy does the job.

Mahdi-zarei commented 2 weeks ago

Sing-tun can be used in windows7. Just use go 1.20 and gvisor stack.

It also seems that an older version of Qt should be used (which has memory related bugs it appears). I guess it's best to wait and see if there is any significant need for the old build.

Maybe you can use some patches to make QT 6.5 works on Windows 7. https://forum.qt.io/topic/133002/qt-creator-6-0-1-and-qt-6-2-2-running-on-windows-7/

Since I do not have a Win7 platform to test on, I don't know if the changes are feasible. By the way, why not upgrade the windows? windows 10 requires the same HW as windows 7.

amirhakimnejad commented 2 weeks ago

Just tested version 4.0.7, 4.0.8 on MacOs 14.5 amd. Works well, thank you. Tested with VLESS ws and reality and VMESS and trojan dns, system proxy mode. Lets me know if you need something specific tested.

can you please test Tun Mode ? image

It turns off right after I try to turn it on, but there are no trace logs. Although system proxy mode works just like tun mode in this version. It tunnels the whole system

That's a bit weird that the system proxy in macOS tunnels the whole device. Can you change Tun stack to gvisor and see if it works? If I remember correctly there are problems with the darwin platform when using system stack.

No difference. Although I managed to keep tun mode on by opening with sudo manually using this: sudo /Applications/nekoray.app/Contents/MacOS/nekoray Now shows this error: start service: initialize inbound/tun[tun-in]: configure tun interface: bad tun name: nekoray-tun

This clarifies things, I assume we could get it to work on the next release, but there is no rush for now since system proxy does the job.

Yes, sure. Thank you for this awesome fork. The VPN performance change is remarkable.

Rosabis commented 2 weeks ago

Sing-tun can be used in windows7. Just use go 1.20 and gvisor stack.

It also seems that an older version of Qt should be used (which has memory related bugs it appears). I guess it's best to wait and see if there is any significant need for the old build.

Maybe you can use some patches to make QT 6.5 works on Windows 7. https://forum.qt.io/topic/133002/qt-creator-6-0-1-and-qt-6-2-2-running-on-windows-7/

Since I do not have a Win7 platform to test on, I don't know if the changes are feasible. By the way, why not upgrade the windows? windows 10 requires the same HW as windows 7.

I tried to upgrade, although their requirements are the same. Windows 10 always runs so slowly on my computer that it can't be used, so I went back to Windows 7.

Mahdi-zarei commented 2 weeks ago

I tried to upgrade, although their requirements are the same. Windows 10 always runs so slowly on my computer that it can't be used, so I went back to Windows 7.

I see, I will try to find a way to support windows 7 as well, but since the linux build pipeline also requires a complete overhauling, this might take some time. On the mean time I suggest you try https://github.com/parhelia512/nekoray-win7.

Mahdi-zarei commented 1 week ago

@Rosabis I was looking for a way to build windows 7 painlessly and found https://github.com/vxiiduu/VxKex/ that allows you to run the mainstream nekoray on windows 7. Could you kindly test it out and if it works, tell me so I can simply build the core with Go 1.20 and ship it with a normal nekoray build.

Rosabis commented 1 week ago

@Rosabis I was looking for a way to build windows 7 painlessly and found https://github.com/vxiiduu/VxKex/ that allows you to run the mainstream nekoray on windows 7. Could you kindly test it out and if it works, tell me so I can simply build the core with Go 1.20 and ship it with a normal nekoray build.

It works, except TUN mode, when I turn it on, nekoray will loop and crash.

Mahdi-zarei commented 1 week ago

@Rosabis I was looking for a way to build windows 7 painlessly and found https://github.com/vxiiduu/VxKex/ that allows you to run the mainstream nekoray on windows 7. Could you kindly test it out and if it works, tell me so I can simply build the core with Go 1.20 and ship it with a normal nekoray build.

It works, except TUN mode, when I turn it on, nekoray will loop and crash.

That was expected, try gvisor too. I guess using this tool we can easily substitute the core with one built with Go 1.20 and have everything working (except system Tun mode of course).

Rosabis commented 1 week ago

@Rosabis I was looking for a way to build windows 7 painlessly and found https://github.com/vxiiduu/VxKex/ that allows you to run the mainstream nekoray on windows 7. Could you kindly test it out and if it works, tell me so I can simply build the core with Go 1.20 and ship it with a normal nekoray build.

It works, except TUN mode, when I turn it on, nekoray will loop and crash.

That was expected, try gvisor too. I guess using this tool we can easily substitute the core with one built with Go 1.20 and have everything working (except system Tun mode of course).

I have also tried to change mixed to gvisor in tun mode and enable TUN mode again, it still crash. Here is the log. https://pastebin.com/XBRTQRyv

Mahdi-zarei commented 1 week ago

Thanks for the info! I will try and provide a windows7 with gvisor support in the next release.