6 chdir '../lib/ExtUtils/CBuilder'
7 or die "Can't chdir to lib/ExtUtils/CBuilder: $!";
14 BEGIN { plan tests => 11 }
16 use ExtUtils::CBuilder;
20 # TEST doesn't like extraneous output
21 my $quiet = $ENV{PERL_CORE} && !$ENV{HARNESS_ACTIVE};
23 my $b = ExtUtils::CBuilder->new(quiet => $quiet);
28 my $source_file = File::Spec->catfile('t', 'compilet.c');
31 open FH, "> $source_file" or die "Can't create $source_file: $!";
32 print FH "int boot_compilet(void) { return 1; }\n";
37 my $object_file = $b->object_file($source_file);
40 ok $object_file, $b->compile(source => $source_file);
42 my $lib_file = $b->lib_file($object_file);
45 my ($lib, @temps) = $b->link(objects => $object_file,
46 module_name => 'compilet');
50 for ($source_file, $lib_file, $object_file) {
55 my @words = $b->split_like_shell(' foo bar');