configure, WIN32

T

Torsten Mohr

Hi,

i'd like to compile Perl on WIN32, i already did that by
using the supplied Makefile for "nmake" and it went fine.

But i'd like to pass some additional parameters to the
compile process.

Is there a way to pass some more parameters to "configure"
on WIN32?

Do i need to use MinGW then?


Thanks for hints,
Torsten.
 
S

Sisyphus

Torsten said:
Hi,

i'd like to compile Perl on WIN32, i already did that by
using the supplied Makefile for "nmake" and it went fine.

But i'd like to pass some additional parameters to the
compile process.

Is there a way to pass some more parameters to "configure"
on WIN32?

Do i need to use MinGW then?

Have you ruled out Cygwin for this ? Strikes me that it's probably your
best chance of success. See 'README.cygwin' in the perl source distro.

If you're committed to native Win32, and thinking of starting with
'./configure', then look at using the Mingw compiler in an MSYS shell -
but I don't fancy your chances with this approach.

Cheers,
Rob
 
C

Chris

Torsten said:
Hi,

i'd like to compile Perl on WIN32, i already did that by
using the supplied Makefile for "nmake" and it went fine.

But i'd like to pass some additional parameters to the
compile process.

Is there some reason you've chosen to eliminate ActiveState Perl as a
choice for Win32 Perl? As hopeless as the Windows platform is, at least
THAT package does provide more than reasonable service to Win32 users.
It's "free," complete, powerful and pain-free to install... I'd go so
far as to say it's the de facto Perl standard on Win32 platforms.

Chris
 
T

Torsten Mohr

But i'd like to pass some additional parameters to the
Is there some reason you've chosen to eliminate ActiveState Perl as a
choice for Win32 Perl?

Yes, and you already quoted it. I want to pass additional parameters
to the build process to build a STATIC version of libperl. I want
to link my own programs against it to execute internal scripts.

I already did this for libperl58.dll, but i don't want the dependency on
the external dll.


Best regards,
Torsten.
 
T

Torsten Mohr

Is there a way to pass some more parameters to "configure"
Have you ruled out Cygwin for this ? Strikes me that it's probably your
best chance of success. See 'README.cygwin' in the perl source distro.

If you're committed to native Win32, and thinking of starting with
'./configure', then look at using the Mingw compiler in an MSYS shell -
but I don't fancy your chances with this approach.

Thanks for that hint, but it didn't really bring me any further.
"Configure -d -Uusedl" starts fine, asks for the C library, continues
and at some point doesn't find some functions and then doesn't write
a Makefile.  No way to continue...

Any other ideas?

I'd like pure native Win32, but i at least tried cygwin.  Configure
stops quite early there.


Best regards,
Torsten.
 
B

Ben Morrow

Torsten Mohr said:
Thanks for that hint, but it didn't really bring me any further.
"Configure -d -Uusedl" starts fine, asks for the C library, continues
and at some point doesn't find some functions and then doesn't write
a Makefile.  No way to continue...

Any other ideas?

README.win32 (you *have* read it?) says you need to use dmake and the
makefile in win32/. Looking at it, you should (maybe) be able to get a
static build by unpacking the extensions you need under ext/ and then
changing the definition of STATIC_EXT in makefile.mk to include them
all. DYNAMIC_EXT should be empty.

NB: I've no idea if this will work.... :)

Ben
 
T

Torsten Mohr

Hi,
README.win32 (you *have* read it?) says you need to use dmake and the
makefile in win32/. Looking at it, you should (maybe) be able to get a
static build by unpacking the extensions you need under ext/ and then
changing the definition of STATIC_EXT in makefile.mk to include them
all. DYNAMIC_EXT should be empty.

thanks for that hint. Yes, i have read README.win32, but i skipped
makefile.mk as it didn't work with nmake. I'll get dmake and try...


Best regards,
Torsten.
 
T

Torsten Mohr

Hi,

just today i've tried.

Using "dmake" works fine, but i think i should somehow define that
i don't want to generate a DLL, just a LIB.

I don't know if this can be done with changes only in the Makefile,
i think that every code for a DLL also needs to contain "DllMain",
correct?

So just changing the Makefile to generate a LIB instead of a DLL
won't work, correct?

I also need to tell XS and other tools to generate code that compiles
for a LIB? How can i do that?

I also need to call the xs_init() of all the modules that are linked
into the LIB? Do i need to do this manually or is there a better way?


Thanks for hints,
Torsten.
 
B

Ben Morrow

Torsten Mohr said:
Hi,


just today i've tried.

Using "dmake" works fine, but i think i should somehow define that
i don't want to generate a DLL, just a LIB.

This is what STATIC_EXT should do for you.
I also need to tell XS and other tools to generate code that compiles
for a LIB? How can i do that?

Everything gets its info from the perl binary it uses, also from its
Config.pm. If both those are correct, you should be fine (assuming
static builds work on Win32 at all).
I also need to call the xs_init() of all the modules that are linked
into the LIB? Do i need to do this manually or is there a better way?

See ExtUtils::Embed.

Ben
 
T

Torsten Mohr

Hi,

thanks for the hints.
This is what STATIC_EXT should do for you.

It didn't, I still get a LIB file of 2xx kB and a DLL of 7xx kB.
I looked through the makefile.mk, but didn't yet succeed to
find the necessary changes.
I think i'll try to just change the option "-dll" to "-lib", but
i'd really wonder if that would succeed.
Everything gets its info from the perl binary it uses, also from its
Config.pm. If both those are correct, you should be fine (assuming
static builds work on Win32 at all).

So i'll try to remove dynamic loading in the configuration, hope that
works.
See ExtUtils::Embed.

Looks really useful.


Thanks for those hints,
Torsten.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top