Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

I saw the MS VC7 compiler offered, downloaded it, posted the news, downloaded the necessary libraries, and tried to build Perl with it. I had to patch Makefile so that the build process for miniperl works:

  • msvcrt.lib seems gone, so I substituted libc.lib for that
  • The delayed loading of winsock.dll doesn't seem to work, so I removed it
  • The compiler wants a special command line switch, /ML, if it should link to libc, so I changed that too.

This is the diff of my 5.9.1 Makefile, as downloaded from perl.com :

< DELAYLOAD = -DELAYLOAD:wsock32.dll -DELAYLOAD:shell32.dll delayi +mp.lib --- > #DELAYLOAD = -DELAYLOAD:wsock32.dll -DELAYLOAD:shell32.dll delayi +mp.lib > DELAYLOAD = 347c348,349 < LIBC = msvcrt.lib --- > #LIBC = msvcrt.lib > LIBC = libc.lib 356c358,359 < OPTIMIZE = -Od -MD -Zi -DDEBUGGING --- > #OPTIMIZE = -Od -MD -Zi -DDEBUGGING > OPTIMIZE = -Od -ML -Zi -DDEBUGGING 360c363,364 < OPTIMIZE = -MD -DNDEBUG --- > #OPTIMIZE = -MD -DNDEBUG > OPTIMIZE = -ML -DNDEBUG 396c400 < CFLAGS = -nologo -Gf -W3 $(INCLUDES) $(DEFINES) $(LOC +DEFS) \ --- > CFLAGS = -nologo -GF -W3 $(INCLUDES) $(DEFINES) $(LOC +DEFS) \ 569c573 < # We need this for miniperl build unless we override canned --- > # We need this for miniperl build unless we override canned 788c792 < "ccflags=-nologo -Gf -W3 $(OPTIMIZE:"=\") $(DEFINES) $ +(BUILDOPT)" \ --- > "ccflags=-nologo -GF -W3 $(OPTIMIZE:"=\") $(DEFINES) $ +(BUILDOPT)" \ 820c824 < perlglob$(o) setargv$(o) --- > perlglob$(o) $(SETARGV_OBJ)

Miniperl builds OK, but when I do nmake test, I get an access violation in the newly created perl.exe for some instruction at 0x77892373, which tried to read memory at 0x000000000f - so I did something wrong while slashing around in the Makefile. But what?

Update: Rephrased the last paragraph


In reply to Building Perl with the free MSVC tools by Corion

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others meditating upon the Monastery: (4)
As of 2024-04-19 14:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found