summaryrefslogtreecommitdiff
path: root/source4/build
diff options
context:
space:
mode:
Diffstat (limited to 'source4/build')
-rw-r--r--source4/build/pidl/NOTES.txt14
-rw-r--r--source4/build/pidl/header.pm2
-rw-r--r--source4/build/pidl/util.pm7
3 files changed, 19 insertions, 4 deletions
diff --git a/source4/build/pidl/NOTES.txt b/source4/build/pidl/NOTES.txt
index d4429fffa4..4f729ecb95 100644
--- a/source4/build/pidl/NOTES.txt
+++ b/source4/build/pidl/NOTES.txt
@@ -1,3 +1,17 @@
+midl types
+----------
+
+pidl uses slightly different types to midl by default. The following
+defines in your MS IDL may make things easier to use the same IDL on
+both platforms.
+
+#define unistr [string] wchar_t *
+#define uint8 char
+#define uint16 short
+#define uint32 long
+#define HYPER_T hyper
+
+
FIXED ARRAY
-----------
diff --git a/source4/build/pidl/header.pm b/source4/build/pidl/header.pm
index 0822ca0e06..dda7e10425 100644
--- a/source4/build/pidl/header.pm
+++ b/source4/build/pidl/header.pm
@@ -127,6 +127,8 @@ sub HeaderType($$$)
$res .= "const char";
} elsif ($data =~ "nstring") {
$res .= "const char *";
+ } elsif ($data =~ "lstring") {
+ $res .= "const char *";
} elsif (util::is_scalar_type($data)) {
$res .= "$data";
} elsif (util::has_property($e, "switch_is")) {
diff --git a/source4/build/pidl/util.pm b/source4/build/pidl/util.pm
index c18fe031f9..192d56316a 100644
--- a/source4/build/pidl/util.pm
+++ b/source4/build/pidl/util.pm
@@ -329,10 +329,9 @@ sub c_pull_prefix($)
return "&";
}
- if ($e->{TYPE} =~ "unistr.*") {
- return "&";
- }
- if ($e->{TYPE} =~ "nstring.*") {
+ if ($e->{TYPE} =~ "unistr.*" ||
+ $e->{TYPE} =~ "nstring.*" ||
+ $e->{TYPE} =~ "lstring.*") {
return "&";
}