diff options
author | markm <markm@FreeBSD.org> | 2002-05-16 10:09:28 +0000 |
---|---|---|
committer | markm <markm@FreeBSD.org> | 2002-05-16 10:09:28 +0000 |
commit | f56e05005c751822074f0a22aa9a98d2eb189924 (patch) | |
tree | e28fc632241c9d248069d45dd9ab2a41fa64868f /contrib/perl5/h2pl/mksizes | |
parent | 344ddc14973a1519f100f54051dcb068069fe43c (diff) | |
download | FreeBSD-src-f56e05005c751822074f0a22aa9a98d2eb189924.zip FreeBSD-src-f56e05005c751822074f0a22aa9a98d2eb189924.tar.gz |
Perl is no longer in base. Long live the port!
Diffstat (limited to 'contrib/perl5/h2pl/mksizes')
-rw-r--r-- | contrib/perl5/h2pl/mksizes | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/contrib/perl5/h2pl/mksizes b/contrib/perl5/h2pl/mksizes deleted file mode 100644 index cb4b8ab..0000000 --- a/contrib/perl5/h2pl/mksizes +++ /dev/null @@ -1,42 +0,0 @@ -#!/usr/local/bin/perl - -($iam = $0) =~ s%.*/%%; -$tmp = "$iam.$$"; -open (CODE,">$tmp.c") || die "$iam: cannot create $tmp.c: $!\n"; - -$mask = q/printf ("$sizeof{'%s'} = %d;\n"/; - -# write C program -select(CODE); - -print <<EO_C_PROGRAM; -#include <sys/param.h> -#include <sys/types.h> -#include <sys/socket.h> -#include <net/if_arp.h> -#include <net/if.h> -#include <net/route.h> -#include <sys/ioctl.h> - -main() { -EO_C_PROGRAM - -while ( <> ) { - chop; - printf "\t%s, \n\t\t\"%s\", sizeof(%s));\n", $mask, $_,$_; -} - -print "\n}\n"; - -close CODE; - -# compile C program - -select(STDOUT); - -system "cc $tmp.c -o $tmp"; -die "couldn't compile $tmp.c" if $?; -system "./$tmp"; -die "couldn't run $tmp" if $?; - -unlink "$tmp.c", $tmp; |