File: mkhephaestus.PL

package info (click to toggle)
horae 071~svn536-1
  • links: PTS
  • area: contrib
  • in suites: wheezy
  • size: 12,996 kB
  • sloc: perl: 67,215; lisp: 744; sh: 78; makefile: 76; ansic: 35
file content (15 lines) | stat: -rwxr-xr-x 565 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/usr/bin/perl -w
use Fatal qw(open close);
my $mode = 0755;

## ----- build HEPHAESTUS
(-e "bin/hephaestus") and unlink "bin/hephaestus";
open my $TO, ">bin/hephaestus";
foreach my $p (qw(head absorption formula data f1f2 ion transition find line misc)) {
  open my $FROM, "hephaestus_parts/$p.pl" or die "could not open parts/$p.pl for reading\n";
  foreach my $line (<$FROM>) { print $TO $line };
  close $FROM
};
close $TO;
print "===> Assembled bin/hephaestus from its parts (hephaestus_parts/) and wrote to bin/hephaestus.\n";
chmod $mode, 'bin/hephaestus';