1#!/usr/local/bin/perl
2#
3# unix.pl - the standard unix makefile stuff.
4#
5
6$o='/';
7$cp='/bin/cp';
8$rm='/bin/rm -f';
--- 56 unchanged lines hidden (view full) ---
65 $ret.="$target: \$(${Name}OBJ)\n";
66 $ret.="\t\$(RM) $target\n";
67 $ret.="\t\$(MKLIB) $target \$(${Name}OBJ)\n";
68 $ret.="\t\$(RANLIB) $target\n\n";
69 }
70
71sub do_link_rule
72 {
73 local($target,$files,$dep_libs,$libs,$sha1file,$openssl)=@_;
74 local($ret,$_);
75
76 $file =~ s/\//$o/g if $o ne '/';
77 $n=&bname($target);
78 $ret.="$target: $files $dep_libs\n";
79 $ret.="\t\$(LINK) ${efile}$target \$(LFLAGS) $files $libs\n";
80 if (defined $sha1file)
81 {
82 $ret.="\t$openssl sha1 -hmac etaonrishdlcupfm -binary $target > $sha1file";
83 }
84 $ret.="\n";
85 return($ret);
86 }
87
88sub which
89 {
90 my ($name)=@_;
91 my $path;
92 foreach $path (split /:/, $ENV{PATH})
93 {
94 if (-x "$path/$name")
95 {
96 return "$path/$name";
97 }
98 }
99 }
100
1011;
2#
3# unix.pl - the standard unix makefile stuff.
4#
5
6$o='/';
7$cp='/bin/cp';
8$rm='/bin/rm -f';
--- 56 unchanged lines hidden (view full) ---
65 $ret.="$target: \$(${Name}OBJ)\n";
66 $ret.="\t\$(RM) $target\n";
67 $ret.="\t\$(MKLIB) $target \$(${Name}OBJ)\n";
68 $ret.="\t\$(RANLIB) $target\n\n";
69 }
70
71sub do_link_rule
72 {
73 local($target,$files,$dep_libs,$libs,$sha1file,$openssl)=@_;
74 local($ret,$_);
75
76 $file =~ s/\//$o/g if $o ne '/';
77 $n=&bname($target);
78 $ret.="$target: $files $dep_libs\n";
79 $ret.="\t\$(LINK) ${efile}$target \$(LFLAGS) $files $libs\n";
80 if (defined $sha1file)
81 {
82 $ret.="\t$openssl sha1 -hmac etaonrishdlcupfm -binary $target > $sha1file";
83 }
84 $ret.="\n";
85 return($ret);
86 }
87
88sub which
89 {
90 my ($name)=@_;
91 my $path;
92 foreach $path (split /:/, $ENV{PATH})
93 {
94 if (-x "$path/$name")
95 {
96 return "$path/$name";
97 }
98 }
99 }
100
1011;