Page 1 of 1

Cruel and Unusual Acts-Build/Run Linux Minetest on Windows!

PostPosted: Wed Sep 21, 2016 13:04
by lordfingle
Image

I thought it might be fun to run minetest as a Linux application on my Windows box in order to test os.execute() commands. (I have mainly developed on Windows previously) I achieved this using the Microsoft "bash" shell for Windows 10. This is actually a partial port of Ubuntu, so it's capable of compiling and running our favourite game.

If you would like to follow in my footsteps, here's what to do:

1. Install the Windows 10 Anniversary Update

http://www.windowscentral.com/how-get-w ... ary-update

2. Enable the Bash Windows Feature

http://www.howtogeek.com/249966/how-to- ... indows-10/


Note: I tried just "apt-get"ting minetest binaries for ubuntu, but these failed.

3. Install an XServer

To run graphical applications, install a Windows XServer.

I used xming:
https://sourceforge.net/projects/xming/

(There is also XServer : https://sourceforge.net/projects/vcxsrv/)

4. Follow the "Compiling on GNU/Linux" instructions

http://dev.minetest.net/Compiling_Minetest

NOTE: Unfortunately sound support failed. To Compile, use this commandline:

cmake . -DENABLE_GETTEXT=1 -DENABLE_FREETYPE=1 -DENABLE_LEVELDB=1 -DENABLE_REDIS=1 -DENABLE_SOUND=0

5. Run minetest (and get dizzy from the mouse being too sensitive)

6. Tune mouse sensitivity:

I am using the following minetest.conf setting

mouse_sensitivity = 0.008

That's it!

As I said previously I think this will be great for ensuring your mods work on both linux and windows using the same environment.

If you're a Linux compilation person, perhaps you could comment on the mouse sensitivity issue or sound support?

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Wed Sep 21, 2016 13:14
by ExeterDad
Say what?!!
Microsoft has worked with Canonical to offer a full Ubuntu-based Bash shell that runs atop this subsystem. Technically, this isn’t Linux at all. Linux is the underlying operating system kernel, and that isn’t available here. Instead, this allows you to run the Bash shell.....


Mind blown.

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Wed Sep 21, 2016 13:40
by lordfingle
As I've demonstrated it's more than just bash. It gives the ability to run any Linux application. (Kinda like a reverse WINE except it's actually using Ubuntu code)

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Thu Sep 22, 2016 00:04
by kaeza
If only it could run Cygwin...

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Fri Sep 23, 2016 01:46
by TARD
lordfingle wrote:I thought it might be fun to run minetest as a Linux application on my Windows box


nice try NSA -_-

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Sat Sep 24, 2016 01:48
by MineYoshi
TARD wrote:
lordfingle wrote:I thought it might be fun to run minetest as a Linux application on my Windows box


nice try NSA -_-

I think that Windows is getting without ideas, and tries to get mostly people from Linux Community... Sometimes i think Micro$oft is tryin' to make good Linux open coders do closed-source software exclussively for Windows, if they weren't happy with all that "exclusively" software they have...
Since nobody watches you when you use Linux (I think many people must learn from hackers, even with the "wrong" and "incorrect" acts they do) you have privacy, i think that Windows is slow because it has a script recording your activity...

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Sun Sep 25, 2016 17:03
by taikedz
This is an interesting development.. i guess it also means you could run the server on windows?

If so it indicates a shrewd move on microsofts behalf. No need for linux to run linux server cimponents. And enterprises can run their MS apps on windows and hhave their linux components ob same machine. On azure of course.....

Sneaky sods.

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Mon Oct 03, 2016 06:41
by lordfingle
You can run minetest as a server (binary) on windows anyways....I'm not sure why you'd want to run the Linux version there (other than to test to ensure it works on Linux)

Windows has always had the ability to run posix subsystems, this is just an ubuntu version.

They say the bash shell is there to assist with using o/s scripts and tools and it certainly seems that way to me. It's not particularly efficient to run server processes.

I think what's weirder is the whole ".net core" effort, which means using Microsoft tooling to deploy to Linux servers - which seems to be going the opposite way?

I know it would take alot to convince you Linux guys that Microsoft is changing when it comes to source code. It is true however that they'd love everyone to be using Azure in the future. Maybe there's something in that.It has even been said they're getting out of the operating system business in the future - http://www.thewindowsclub.com/why-is-mi ... pen-source

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Mon Oct 03, 2016 10:41
by taikedz
I was more thinking, if it can run the actual Linux binary server on Windows, it indicates that Windows has a good chance of running a much larger number of Linux server binaries, even ones that aren't designed to run on anything other than Linux.

For the efforts in the other direction - it makes sense in the old model (the infamous Embrace, Extend, Extinguish) - here's an example scenario:

Provide .net framework to Linux and have it adopted by enterprises ; gradually increase proprietary requirements and adjust licensing, then drop the Linux support further down the line. Sufficient portions of the API are no longer open source, and the FOSS effort would need time to catch up.

Enterprises being what they are, they are more likely to try to maintain an application stack come what may. If that means moving everything back over to a Windows system, and hosting their previously Linux server apps on Windows too, they'll do it.

It's not going to destroy open source operating systems, but it will certainly be a major nuisance for sysadmins and developers who need to work on migrating all that nonsense, for the sake of a few more millions in MS's coffers (and at enterprise level, millions is a paltry amount....). Developers who had faith that it would remain open source are now faced with completely rewriting their stack, sticking with Windows for the rest of the life of the project, or abandoning the project altogether.

So far, still best to not touch anything from software companies with bad histories.

Unfortunately, Microsoft has had a very clear and negative track record, and as you can appreciate, it's a lot easier to destroy trust than it is to build it. We've been bitten several times before, and there's no reason to believe that anything's going to change.

MS exiting the OS game? Rubbish. Jerry Nixon said "Windows 10 is the last version." There have been speculations of Windows as a Service, Windows 10.x rolling releases, Windows 10.x versioning .... I'll believe it only when it happens.

Project Redstone (oh the irony!) looks like it's a rolling-release project http://www.theverge.com/2015/4/7/836435 ... ws-updates

It is also relevant to note that Windows Server is a different operating system (in terms of project efforts at the very least), and is still being released.

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Wed Oct 05, 2016 11:32
by Wuzzy
I agree, these are indeed cruel and unsual acts. Also, I don't get it. What's the point?

I thought it might be fun to run minetest as a Linux application on my Windows box in order to test os.execute() commands.

I think os.execute() commands should be kept out of any Minetest mod like a pest as this makes your mod platform-dependent. This is really stupid since mods are platform-independent by default, unless you really WANT it to platform-dependent. Please let's not open this can of worms. Life was so much easier when we could rely on the fact that mods run on ALL operating systems on which Minetest runs. I would hate to see the mods degrade into tons of platform-dependent bullcrap. So please don't even START with stuff like this.

As I said previously I think this will be great for ensuring your mods work on both linux and windows using the same environment.

Why jumping through so many hoops when it is so much simpler to not making your mods platform-dependent in the first place? Just don't use os.execute. Duh!


By the way:
Microsoft "bash" shell for Windows 10.

MICROSOFT bash? No, just, no.
It's probably just the “GNU Bash”, commonly called “bash”, used on practically all GNU/Linux distributions like Ubuntu, Linux Mint, OpenSUSE, Arch Linux, etc.
https://www.gnu.org/software/bash/

It's scary to see that people actually think that GNU software comes from Microsoft.

Besides, this looks like a fatal case of Not Invented Here to me. Cygwin already added Bash support for Windows years ago.

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Wed Oct 05, 2016 12:29
by taikedz
Wuzzy wrote:By the way:
Microsoft "bash" shell for Windows 10.

MICROSOFT bash? No, just, no.
It's probably just the “GNU Bash”, commonly called “bash”, used on practically all GNU/Linux distributions like Ubuntu, Linux Mint, OpenSUSE, Arch Linux, etc.
https://www.gnu.org/software/bash/

It's scary to see that people actually think that GNU software comes from Microsoft.


I share the sentiment; though on the other hand, whatever crippled limitations it may eventually develop in that implementation I might prefer to see remain under Microsoft's label.... maybe the correct name would be "Microsoft's GNU bash" ?

My penny for your two cents.

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Wed Oct 05, 2016 12:53
by Wuzzy
According to http://www.howtogeek.com/249966/how-to- ... indows-10/

MS is using the GNU Bash as distributed in Ubuntu, so only the name “GNU Bash” (or “bash” for short) is the correct one. That is, IF we can trust this article.

I don't really trust this article since they don't know shit about GNU:
The Bash shell you’ll get is really just all those GNU utilities and other software.

First, it's not “the Bash shell” and second, the bash does not contain “all those GNU utilities”, it is just the bash.

EDIT: Ooops, all of this is way too off topic. Sorry for this. I better shut up about this bash stuff from now.

Re: Cruel and Unusual Acts-Build/Run Linux Minetest on Windo

PostPosted: Sun Oct 16, 2016 16:59
by red-001
See https://github.com/aseering/wsl_gui_autoinstall for how to get pulseaudio to work.