Fix for Bug 1371 - avoid generating OpenVG stub functions with invalid IMPORT_C decorations
authorWilliam Roberts <williamr@symbian.org>
Fri, 27 Nov 2009 12:19:45 +0000
changeset 3 3c318bb9d9cf
parent 2 fee529991771
child 4 97befe7e0e71
Fix for Bug 1371 - avoid generating OpenVG stub functions with invalid IMPORT_C decorations
sbsv1_os/e32toolp/genutil/conv_khronos_openvg_hdr_to_cpp.pl
--- a/sbsv1_os/e32toolp/genutil/conv_khronos_openvg_hdr_to_cpp.pl	Mon Feb 08 18:14:56 2010 +0000
+++ b/sbsv1_os/e32toolp/genutil/conv_khronos_openvg_hdr_to_cpp.pl	Fri Nov 27 12:19:45 2009 +0000
@@ -62,11 +62,12 @@
   {
     @lines = <INFILE>;
     my $s = "";
-    foreach (@lines) {
+    foreach my $line (@lines) {
       # Find function prototype lines
-      if (/^VG[U]?_API_CALL/ || length($s) != 0) {
-	    $s = $s.$_;
-		if (/;/) {
+      if ($line =~ /^VG[U]?_API_CALL/ || length($s) != 0) {
+      $line =~ s/^VG[U]?_API_CALL/EXPORT_C/;
+	    $s = $s.$line;
+		if ($line =~ /;/) {
 		  # Convert the function prototype into a stub function definition
 		  $s =~ s/\;$/ { }/;
 		  # Record the stub functions.  There will be a stub implementation