From c9a77dc3c7306de255daee5eeba08920f06bb2e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Love=20H=C3=B6rnquist=20=C3=85strand?= Date: Tue, 13 Apr 2004 14:33:07 +0000 Subject: [PATCH] if -E, add windows standard calling conv to headerfile if needed git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13712 ec53bebd-3082-4978-b11e-865c3cabbd6b --- cf/make-proto.pl | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/cf/make-proto.pl b/cf/make-proto.pl index 6a15f7a2c..3129bf683 100644 --- a/cf/make-proto.pl +++ b/cf/make-proto.pl @@ -10,7 +10,7 @@ $debug = 0; $oproto = 1; $private_func_re = "^_"; -do Getopts('x:m:o:p:dqR:P:') || die "foo"; +do Getopts('x:m:o:p:dqE:R:P:') || die "foo"; if($opt_d) { $debug = 1; @@ -256,6 +256,27 @@ if($opt_m ne "roken") { "; } + if ($opt_E) { + $public_h_header .= "#ifndef $opt_E +#if defined(_WIN32) +#define $opt_E _stdcall +#else +#define $opt_E +#endif +#endif + +"; + + $private_h_header .= "#ifndef $opt_E +#if defined(_WIN32) +#define $opt_E _stdcall +#else +#define $opt_E +#endif +#endif + +"; + } if ($public_h ne "") { $public_h = $public_h_header . $public_h . "#endif /* $block */\n";