in reply to Adding dependencies to the generated Makefile

http://search.cpan.org/~mschwern/ExtUtils-MakeMaker-6.48/lib/ExtUtils/MakeMaker.pm#depend
  • Comment on Re: Adding dependencies to the generated Makefile

Replies are listed 'Best First'.
Re^2: Adding dependencies to the generated Makefile
by casiano (Pilgrim) on Oct 29, 2008 at 12:15 UTC
    Thanks.
    I already tried this but I am failing:
    $ cat Makefile.PL use warnings; use strict; use ExtUtils::MakeMaker; WriteMakefile( NAME => 'Math::Calc', VERSION => '1.0', PREREQ_PM => {}, # e.g., Module::Name => 1.1 EXE_FILES => [ 'scripts/calc.pl' ], ABSTRACT_FROM => 'lib/Math/Calc.pod', # retrieve abstract from + pod AUTHOR => 'Procesadores de Lenguaje <casiano@ull.es>', depend => { 'test' => 'calc' }, ); sub MY::postamble { return <<'EOM'; calc: lib/Math/Calc.pm lib/Math/Calc.pm: lib/Math/Calc.eyp eyapp -s -m Math::Calc -o lib/Math/Calc.pm lib/Math/Calc.eyp myclean: veryclean rm -f Math-Calc-*.tar.gz cover -delete rmcalc: rm -f lib/Math/Calc.pm mytest: calc test remotetest: calc dist remotetest.pl ${DISTVNAME}.tar.gz orion beowulf coverage: calc cover -delete make HARNESS_PERL_SWITCHES=-MDevel::Cover test cover EOM }
    It says s.t. like:
    $ perl Makefile.PL Writing Makefile for Math::Calc $ make test Makefile:779: *** el archivo de objetivos `test' tiene líneas con : y +::. Alto.
    Waht I am doing wrong?
    I also unsuccessfully tried to add a colon to the target descriptor:
    depend => { 'test:' => 'calc' },
      Ouch. How about an example we can try? With error messages we don't have to translate? :)

      update: ok, after finding something to test, your error appears to be same as NMAKE Fatal Error U1087 (cannot have : and :: dependents for same target) which appears to be what ExtUtils::MakeMaker warned about (ANY_TARGET must not be given a double-colon rule by MakeMaker.). Maybe you can switch to Module::Build?