Re: Line too long on windows with msys



Flash news : working around the line limit was as simple as :

- dmake >build.log

- wrap the content with :

use strict ;
use constant DEBUG => 1 ;

my $cmds = <<'EOC' ;
<content of build.log>
EOC

for my $cmd (split("\n",$cmds))
{
    my @args = split(' ',$cmd) ;
    system(@args) ;
    if ($?)
    {
        die "Cannot execute [$cmd]: $!\n" ;
        warn "Args was:[".join("]\n[",@args)."]\n" if (DEBUG >= 1) ;
    }
}

Yes, I  know, if some spaces  appears in file names  it will fail
(but I don't care for now, I just want to validate the build).

Thanks perl, shame on cmd.exe.

But see  my other email for  next problem and read  this one for
further questions if time permits (thanks in advance).

"muppet" == Muppet  <scott asofyet org> writes:

    muppet> Vincent LADEUIL said:
    >> Questions :
    >> 
    >> - can we put all the object filenames into a file and give
    >> that to g++ ?

    muppet> I think what you're really after is "can i specify
    muppet> the list of object files in a linker script?"  

More or less, linker scripts  are black voodoo for me (working in
the embedded field I know what they are about but I never have to
build one myself).

I was more  fishing for just a list of files  to replace those on
the command lines.

    muppet> and i don't know the answer to that, although i
    muppet> suspect it is possible.

Hmmm...

    >> - can we create intermediate libraries and give them to
    >> the final link stage ?

    muppet> I  have not tried doing  this, and i'm  not sure what
    muppet> would actually happen if creating static archives and
    muppet>  linking  those into  a  dll.   It  should be  fairly
    muppet> straightforward  to use "ar -ru" on  each object file
    muppet>  as  it  is  made to  simulate  incremental  linking.

Yeah, I was thinking along these line.

    muppet>  Getting such a scheme to work portably 

Portably... yeah, the hard part :(

    muppet> with a generated makefile is a different issue, but
    muppet> we'll tackle that one iff you can prove that it would
    muppet> work.

Ok.

Thanks for your prompt answers.

Others ideas :

- is migrating to Module::Build on the agenda ?

- do  you want  some feedback  on the  failed tests  (when  I get
  there)  ? Or  more precisely,  what  should I  deduce from  the
  tests,  did they  have been  fully  debugged on  windows, on  a
  msys/mingw build ? For Glib and Gtk2 ?

You may not  hear about me 'cause I'll be  in vacations next week
(beginning  tonight)  but I  definitely  will  come  back on  the
subject.

        Vincent



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]