ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/perlkob/Makefile.PL
Revision: 1.1
Committed: Mon Nov 12 16:05:22 2001 UTC (14 years, 8 months ago) by cjm
Branch: MAIN
CVS Tags: HEAD
Log Message:
mostly gui changes

more protege okbc compliancy

Line File contents
1 # Basically this is a standard Makefile with a hash of
2 # needed packages which are tested at the start
3
4 # (plagiarised from the bioperl Makefile.PL)
5
6 %packages = (
7 );
8
9 sub check_package {
10 my ($name,$str) = @_;
11 my($ver,$desc,$expl,@modules);
12
13 ($ver,$desc,$expl,$module) = split( /\// , $str);
14 if( !eval "require $name") {
15 print "** WARNING **\n External Module $name, $desc,\n is not installed on this computer.\n The $module needs it for $expl\n\n";
16 return 1;
17 }
18
19 return 0;
20 }
21
22
23
24 # Let the code begin...
25
26 require 5.6.0;
27 use ExtUtils::MakeMaker;
28
29 $do_autoload_finesse = 0;
30 $NAME = 'perlKOB';
31 $DISTNAME = "perlKOB";
32 $VERSION = "0.01";
33
34 if( $do_autoload_finesse == 1 ) {
35 fatal("Autoload finessing does not work at the moment!");
36 }
37
38 # don't catch signals - it is very boring!
39
40 #BEGIN {
41 ##Catch signals and invoke a cleanup function
42 #$SIG{__WARN__} = $SIG{INT} = $SIG{QUIT} =\&cleanup;
43 #}
44
45 @BACKUP_FILES = ();
46
47 #
48 #
49
50 if( $do_autoload_finesse ) {
51
52 print "module installation\nPreparing modules for AUTOLOADing...";
53 `perl -p -i.bak -e 's/#__END__/__END__/' Seq.pm`;
54 print "done.\n\n";
55 }
56
57 $error = 0;
58 foreach $name ( keys %packages ) {
59 if( &check_package($name,$packages{$name}) == 1 ) {
60 $error = 1;
61 }
62 }
63
64 if (-f "t/go-test-config.pl") {
65 require "t/go-test-config.pl";
66 }
67
68 print <<INTRO_MSG;
69
70 blah
71
72 INTRO_MSG
73
74 if( $error == 1 ) {
75 print <<QQ_ERROR_QQ;
76
77 Warning:
78
79 There are some external packages, listed above, which GO
80 uses.
81
82 The installation of these external packages is very simple. You
83 can find them at www.cpan.org
84
85 please read the file INSTALL
86
87 QQ_ERROR_QQ
88 }
89
90 WriteMakefile(
91 NAME => $NAME,
92 DISTNAME => $DISTNAME,
93 VERSION => $VERSION,
94 'dist' => { COMPRESS => 'gzip -9f',
95 SUFFIX => '.gz',
96 DIST_DEFAULT => 'all tardist',
97 },
98 'install' => 'installmods.pl',
99 'realclean' => { FILES => join(' ',@BACKUP_FILES) }
100 );
101
102
103 sub cleanup {
104 my $sig = @_;
105 print "\n** [$0] Caught a SIG$sig -- cleaning up and shutting down.\n";
106
107 exit(0);
108 }