I've just committed an initial patch that allows Pike to be compiled using mingw32. To compile pike using mingw32, you will have to do the following:
1) Install the latest mingw32-dist 2) Install Msys 3) Install the mingw Win32 API update 4) Install GMP (either from source or bin package) 5) Install Nettle (untested! I've been using --without-nettle for the time beeing...) 6) Get a Pike 7.7 source snapshot (or build one yourself). Building from CVS under mingw32 seems to break due to some cr/lf problem, so build the source-dist on a unix box. 7) Set the PIKE_PATH_TRANSLATE to some sed-command which translates the master-paths from you MSYS installation to the regular NT-CMD filesystem(*). 8) Do "make configure" to configure your buildtree. 9) Do "make" do build pike. 10) (optional) Do "make verify". This will fail, the hard way.. ;( 11) You should now have a pike which is usable to some extent. I havn't tested it much, but I've done some simple tests and it seems to hold up fairly well.
(*) I build from my home-dir, /home/SSS668. To create a working master, I need to translate that path to c:/msys/1.0/home/SSS668. You need to do the same using some creative sed-command or accept that your build will fail when it attepmts to build post_modules. You can modify the master manually if you like. Look for the ¤-sign to find what places to modify.
So, there it is. Now you should know what you need to build. I believe that Mingw32 is the easiest way to get Pike to compile on Win32. However, I'm not so certain it is the best choice since there seems to be quite a few compatibility issues between mingw32 and the win32 api (as MS provides it). I have access to both at work and they do not match in several places.
I believe that we should try to get Pike to work with mingw first, and then start working towards MSVC native compilation. However, there will still be the problem of configuring the build. It may be that we always will need a msys-layer to run configure.
3.5) Install autoconf?
/ Martin Nilsson (räfsfiskal)
Previous text:
2004-05-11 00:05: Subject: Pike @ win32
I've just committed an initial patch that allows Pike to be compiled using mingw32. To compile pike using mingw32, you will have to do the following:
- Install the latest mingw32-dist
- Install Msys
- Install the mingw Win32 API update
- Install GMP (either from source or bin package)
- Install Nettle (untested! I've been using --without-nettle for the
time beeing...) 6) Get a Pike 7.7 source snapshot (or build one yourself). Building from CVS under mingw32 seems to break due to some cr/lf problem, so build the source-dist on a unix box. 7) Set the PIKE_PATH_TRANSLATE to some sed-command which translates the master-paths from you MSYS installation to the regular NT-CMD filesystem(*). 8) Do "make configure" to configure your buildtree. 9) Do "make" do build pike. 10) (optional) Do "make verify". This will fail, the hard way.. ;( 11) You should now have a pike which is usable to some extent. I havn't tested it much, but I've done some simple tests and it seems to hold up fairly well.
(*) I build from my home-dir, /home/SSS668. To create a working master, I need to translate that path to c:/msys/1.0/home/SSS668. You need to do the same using some creative sed-command or accept that your build will fail when it attepmts to build post_modules. You can modify the master manually if you like. Look for the ¤-sign to find what places to modify.
So, there it is. Now you should know what you need to build. I believe that Mingw32 is the easiest way to get Pike to compile on Win32. However, I'm not so certain it is the best choice since there seems to be quite a few compatibility issues between mingw32 and the win32 api (as MS provides it). I have access to both at work and they do not match in several places.
I believe that we should try to get Pike to work with mingw first, and then start working towards MSVC native compilation. However, there will still be the problem of configuring the build. It may be that we always will need a msys-layer to run configure.
/ Marcus Agehall (Scanian)
Only needed if building from CVS. You should really use source-dists if you don't know exactly what you are doing. I got bitten by some bug which seems to break the configure files generated under mingw32. But on the other hand, autoconf shouldn't hurt..
/ Marcus Agehall (Scanian)
Previous text:
2004-05-11 00:15: Subject: Pike @ win32
3.5) Install autoconf?
/ Martin Nilsson (räfsfiskal)
If mingw32 and the related tools does not use windows linebreaks we should most likely not use it, and go with microsofts unix lookalike environment instead.
/ Per Hedbor ()
Previous text:
2004-05-11 00:17: Subject: Pike @ win32
Only needed if building from CVS. You should really use source-dists if you don't know exactly what you are doing. I got bitten by some bug which seems to break the configure files generated under mingw32. But on the other hand, autoconf shouldn't hurt..
/ Marcus Agehall (Scanian)
I think it does, mostly. The problem with generating a native configure-script seems to come from some tool within mingw32 that doesn't work correctly. I didn't investigate futher then, but I probably will, as soon as I know where I can develop on win32.
Right now, I have a friends laptop which is decent that I can use, but that won't last forever. I'm trying to do some development at work, but without CVS-access, it's hard to do things efficient. In a month or so, I'll move back in with my real computer and then I can do some serious debugging of mingw, in case the problem still exists.
On the other hand, if microsoft has some sort of unix-glue that is also interesting. Where can I read more about it? Is it free in some way or do I have to give up my left arm and right leg to have a copy?
/ Marcus Agehall (Scanian)
Previous text:
2004-05-11 00:45: Subject: Pike @ win32
If mingw32 and the related tools does not use windows linebreaks we should most likely not use it, and go with microsofts unix lookalike environment instead.
/ Per Hedbor ()
In the last episode (May 13), Marcus Agehall (Scanian) @ Pike (-) developers forum said:
I think it does, mostly. The problem with generating a native configure-script seems to come from some tool within mingw32 that doesn't work correctly. I didn't investigate futher then, but I probably will, as soon as I know where I can develop on win32.
Another option is cygwin's -mno-cygwin gcc flag, which should basically generate win32 executables like mingw, but autoconf etc might be happier since they'd run in Cygwin's more unixy environment.
On the other hand, if microsoft has some sort of unix-glue that is also interesting. Where can I read more about it? Is it free in some way or do I have to give up my left arm and right leg to have a copy?
http://www.microsoft.com/windows/sfu/ is the main site. I was sure it had been mentioned in this list recently, but apparently not :) It requires windows 2000 or newer, and I don't think it generates standalone executables. You need the Interix subsystem running (similar to the cygwin support DLLs), so mingw is probably still the best choice for building portable binaries.
I have it installed just for the excellent NFS client and server.
Another option is cygwin's -mno-cygwin gcc flag, which should
basically
generate win32 executables like mingw, but autoconf etc might be happier since they'd run in Cygwin's more unixy environment.
Yes, the -mno-cygwin would be an option, but then mingw is much smaller and easier to install imho. It's really a minor problem that you cannot build from CVS but have to use a snapshot to build on win32 at the moment.
/ Marcus Agehall (Scanian)
Previous text:
2004-05-13 16:45: Subject: Re: Pike @ win32
In the last episode (May 13), Marcus Agehall (Scanian) @ Pike (-) developers forum said:
I think it does, mostly. The problem with generating a native configure-script seems to come from some tool within mingw32 that doesn't work correctly. I didn't investigate futher then, but I probably will, as soon as I know where I can develop on win32.
Another option is cygwin's -mno-cygwin gcc flag, which should basically generate win32 executables like mingw, but autoconf etc might be happier since they'd run in Cygwin's more unixy environment.
On the other hand, if microsoft has some sort of unix-glue that is also interesting. Where can I read more about it? Is it free in some way or do I have to give up my left arm and right leg to have a copy?
http://www.microsoft.com/windows/sfu/ is the main site. I was sure it had been mentioned in this list recently, but apparently not :) It requires windows 2000 or newer, and I don't think it generates standalone executables. You need the Interix subsystem running (similar to the cygwin support DLLs), so mingw is probably still the best choice for building portable binaries.
I have it installed just for the excellent NFS client and server.
-- Dan Nelson dnelson@allantgroup.com
/ Brevbäraren
Marcus Agehall (Scanian) @ Pike (-) developers forum wrote:
I've just committed an initial patch that allows Pike to be compiled using mingw32.
Thanks!
To compile pike using mingw32, you will have to do the following:
[snip]
- Install Nettle (untested! I've been using --without-nettle for the
time beeing...)
How/where did you specify this? I've tried with make configure --without-nettle and make --without-nettle configure and make --without-nettle, but it keep telling me it's an unrecognized option.
- Get a Pike 7.7 source snapshot (or build one yourself). Building
from CVS under mingw32 seems to break due to some cr/lf problem, so build the source-dist on a unix box. 7) Set the PIKE_PATH_TRANSLATE to some sed-command which translates the master-paths from you MSYS installation to the regular NT-CMD filesystem(*). 8) Do "make configure" to configure your buildtree. 9) Do "make" do build pike. 10) (optional) Do "make verify". This will fail, the hard way.. ;( 11) You should now have a pike which is usable to some extent. I havn't tested it much, but I've done some simple tests and it seems to hold up fairly well.
(*) I build from my home-dir, /home/SSS668. To create a working master, I need to translate that path to c:/msys/1.0/home/SSS668. You need to do the same using some creative sed-command
[snip]
Thought I'd post an example (what I have): export PIKE_PATH_TRANSLATE="sed s@/dev@f:/work/dev@g"
I'm building in /dev/pike/Pike-v7.7-snapshot which should point to f:/work/dev/pike/Pike-v7.7-snapshot it works as expected with pwd | $PIKE_PATH_TRANSLATE so I hope it does the trick.
Running configure now (with nettle, I suppose) see how it goes :o)
// Andreas
- Install Nettle (untested! I've been using --without-nettle for
the
time beeing...)
How/where did you specify this? I've tried with make configure --without-nettle and make
--without-nettle configure
and make --without-nettle, but it keep telling me it's an
unrecognized option.
make configure CONFIGUREARGS="--without-nettle --without-bundles"
should do it. Another option is, of course, to install nettle. But I didn't bother...
/ Marcus Agehall (Scanian)
Previous text:
2004-05-19 11:00: Subject: Re: Pike @ win32
Marcus Agehall (Scanian) @ Pike (-) developers forum wrote:
I've just committed an initial patch that allows Pike to be compiled using mingw32.
Thanks!
To compile pike using mingw32, you will have to do the following:
[snip]
- Install Nettle (untested! I've been using --without-nettle for the
time beeing...)
How/where did you specify this? I've tried with make configure --without-nettle and make --without-nettle configure and make --without-nettle, but it keep telling me it's an unrecognized option.
- Get a Pike 7.7 source snapshot (or build one yourself). Building
from CVS under mingw32 seems to break due to some cr/lf problem, so build the source-dist on a unix box. 7) Set the PIKE_PATH_TRANSLATE to some sed-command which translates the master-paths from you MSYS installation to the regular NT-CMD filesystem(*). 8) Do "make configure" to configure your buildtree. 9) Do "make" do build pike. 10) (optional) Do "make verify". This will fail, the hard way.. ;( 11) You should now have a pike which is usable to some extent. I havn't tested it much, but I've done some simple tests and it seems to hold up fairly well.
(*) I build from my home-dir, /home/SSS668. To create a working master, I need to translate that path to c:/msys/1.0/home/SSS668. You need to do the same using some creative sed-command
[snip]
Thought I'd post an example (what I have): export PIKE_PATH_TRANSLATE="sed s@/dev@f:/work/dev@g"
I'm building in /dev/pike/Pike-v7.7-snapshot which should point to f:/work/dev/pike/Pike-v7.7-snapshot it works as expected with pwd | $PIKE_PATH_TRANSLATE so I hope it does the trick.
Running configure now (with nettle, I suppose) see how it goes :o)
// Andreas
/ Brevbäraren
Marcus Agehall (Scanian) @ Pike (-) developers forum wrote:
I've tried with make configure --without-nettle and make --without-nettle configure and make --without-nettle, but it keep telling me it's an unrecognized option.
make configure CONFIGUREARGS="--without-nettle --without-bundles"
Ah, goody.
should do it. Another option is, of course, to install nettle. But I didn't bother...
/ Marcus Agehall (Scanian)
[snip]
pike-devel@lists.lysator.liu.se