Hello community, here is the log from the commit of package abi-compliance-checker for openSUSE:Factory checked in at 2017-07-08 12:34:44 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/abi-compliance-checker (Old) and /work/SRC/openSUSE:Factory/.abi-compliance-checker.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "abi-compliance-checker" Sat Jul 8 12:34:44 2017 rev:7 rq:508414 version:2.1 Changes: -------- --- /work/SRC/openSUSE:Factory/abi-compliance-checker/abi-compliance-checker.changes 2017-03-31 15:10:04.847351726 +0200 +++ /work/SRC/openSUSE:Factory/.abi-compliance-checker.new/abi-compliance-checker.changes 2017-07-08 12:34:54.686120929 +0200 @@ -1,0 +2,14 @@ +Wed Jul 5 15:38:54 UTC 2017 - astie...@suse.com + +- update to 2.1: + * Show added v-table symbols for public classes + * Fixed analysis of static methods + * Fixed analysis of typedefs + * Fixed analysis of zero-size structs + * Fixed logs + * Fixed analysis of static libraries on Windows + * Fixed search for files on Windows + * Documented -skip-internal-types option in -help + * Add noindex meta tag to report if no changes detected + +------------------------------------------------------------------- Old: ---- abi-compliance-checker-2.0.tar.gz New: ---- abi-compliance-checker-2.1.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ abi-compliance-checker.spec ++++++ --- /var/tmp/diff_new_pack.DZFIo8/_old 2017-07-08 12:34:55.446013746 +0200 +++ /var/tmp/diff_new_pack.DZFIo8/_new 2017-07-08 12:34:55.450013182 +0200 @@ -17,7 +17,7 @@ Name: abi-compliance-checker -Version: 2.0 +Version: 2.1 Release: 0 Summary: A Compliance Checker For library ABIs License: GPL-2.0+ or LGPL-2.0+ ++++++ abi-compliance-checker-2.0.tar.gz -> abi-compliance-checker-2.1.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/abi-compliance-checker-2.0/INSTALL new/abi-compliance-checker-2.1/INSTALL --- old/abi-compliance-checker-2.0/INSTALL 2017-01-28 17:20:49.000000000 +0100 +++ new/abi-compliance-checker-2.1/INSTALL 2017-06-17 06:59:27.000000000 +0200 @@ -8,8 +8,8 @@ RELEASE INFORMATION Project: ABI Compliance Checker (ABICC) -Version: 2.0 -Date: 2017-01-28 +Version: 2.1 +Date: June 17, 2017 This file explains how to install and setup environment diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/abi-compliance-checker-2.0/abi-compliance-checker.pl new/abi-compliance-checker-2.1/abi-compliance-checker.pl --- old/abi-compliance-checker-2.0/abi-compliance-checker.pl 2017-01-28 17:20:49.000000000 +0100 +++ new/abi-compliance-checker-2.1/abi-compliance-checker.pl 2017-06-17 06:59:27.000000000 +0200 @@ -1,6 +1,6 @@ #!/usr/bin/perl ########################################################################### -# ABI Compliance Checker (ABICC) 2.0 +# ABI Compliance Checker (ABICC) 2.1 # A tool for checking backward compatibility of a C/C++ library API # # Copyright (C) 2009-2011 Institute for System Programming, RAS @@ -58,7 +58,7 @@ use Cwd qw(abs_path cwd); use Data::Dumper; -my $TOOL_VERSION = "2.0"; +my $TOOL_VERSION = "2.1"; my $XML_REPORT_VERSION = "1.2"; my $ABI_DUMP_VERSION = "3.4"; my $ABI_DUMP_VERSION_MIN = "3.2"; @@ -608,10 +608,12 @@ The list of types that should not be checked. -skip-internal-symbols PATTERN - Do not check symbols matched by the pattern. + Do not check symbols matched by the regular expression. -skip-internal-types PATTERN - Do not check types matched by the pattern. + Do not check types matched by the regular expression. + It's matched against full qualified type names (e.g. 'struct xyz::Name<T>'). + It has to match any part of type name. -keep-cxx Check _ZS*, _ZNS* and _ZNKS* symbols. @@ -3064,9 +3066,9 @@ } } - if(not $Type1_Pure{"Size"} - or not $Type2_Pure{"Size"}) - { + if($Type1_Pure{"Size"} eq "" + or $Type2_Pure{"Size"} eq "") + { # NOTE: size of struct may be 0 bytes if($Type1_Pure{"Type"}=~/Class|Struct|Union/) { # including a case when "class Class { ... };" changed to "class Class;" if(not defined $Type1_Pure{"Memb"} or not defined $Type2_Pure{"Memb"} @@ -3530,10 +3532,12 @@ if(my $BSize2 = $Type2_Pure{"Memb"}{$MemberPair_Pos}{"bitfield"}) { $SizeV2 = $BSize2; } + my $MemberType1_Name = $TypeInfo{1}{$MemberType1_Id}{"Name"}; my $MemberType2_Name = $TypeInfo{2}{$MemberType2_Id}{"Name"}; + if($Level eq "Binary" - and $SizeV1 and $SizeV2 + and $SizeV1 ne "" and $SizeV2 ne "" and $SizeV1 ne $SizeV2) { if($MemberType1_Name eq $MemberType2_Name or (isAnon($MemberType1_Name) and isAnon($MemberType2_Name)) @@ -3894,13 +3898,54 @@ } } +sub checkVtable($$$) +{ + my ($Level, $Symbol, $V) = @_; + + # skip v-tables for templates, that should not be imported by applications + if(my $CName = $VTableClass{$V}{$Symbol}) + { + if(index($CName, "<")!=-1) { + return 0; + } + + if(not keys(%{$ClassMethods{$Level}{$V}{$CName}})) + { # do not show vtables for "private" classes + # use case: vtable for QDragManager (Qt 4.5.3 to 4.6.0) became HIDDEN symbol + return 0; + } + } + + if($In::Desc{$V}{"SkipSymbols"}{$Symbol}) + { # user defined symbols to ignore + return 0; + } + + return 1; +} + sub mergeLibs($) { my $Level = $_[0]; foreach my $Symbol (sort keys(%{$AddedInt{$Level}})) { # checking added symbols next if(not $CompSign{2}{$Symbol}{"Header"} and not $CompSign{2}{$Symbol}{"Source"}); - next if(not symbolFilter($Symbol, $CompSign{2}{$Symbol}, "Affected + InlineVirt", $Level, 2)); + + if(index($Symbol, "_ZTV")==0) + { + if(not checkVtable($Level, $Symbol, 2)) { + next; + } + } + else { + next if(not symbolFilter($Symbol, $CompSign{2}{$Symbol}, "Affected + InlineVirt", $Level, 2)); + } + + if($CompSign{2}{$Symbol}{"PureVirt"}) + { # symbols for pure virtual methods cannot be called by clients + next; + } + %{$CompatProblems{$Level}{$Symbol}{"Added_Symbol"}{""}} = (); } foreach my $Symbol (sort keys(%{$RemovedInt{$Level}})) @@ -3908,22 +3953,8 @@ next if(not $CompSign{1}{$Symbol}{"Header"} and not $CompSign{1}{$Symbol}{"Source"}); if(index($Symbol, "_ZTV")==0) - { # skip v-tables for templates, that should not be imported by applications - if(my $CName = $VTableClass{1}{$Symbol}) - { - if(index($CName, "<")!=-1) { - next; - } - - if(not keys(%{$ClassMethods{$Level}{1}{$CName}})) - { # vtables for "private" classes - # use case: vtable for QDragManager (Qt 4.5.3 to 4.6.0) became HIDDEN symbol - next; - } - } - - if($In::Desc{1}{"SkipSymbols"}{$Symbol}) - { # user defined symbols to ignore + { + if(not checkVtable($Level, $Symbol, 1)) { next; } } @@ -6627,6 +6658,9 @@ $TotalSymbols -= keys(%ExtendedSymbols); } + my $AnyChanged = ($Added or $Removed or $I_Problems_High or $I_Problems_Medium or $I_Problems_Low or $T_Problems_High or + $C_Problems_Low or $T_Problems_Medium or $T_Problems_Low or $I_Other or $T_Other or $C_Other); + my ($Arch1, $Arch2) = ($In::ABI{1}{"Arch"}, $In::ABI{2}{"Arch"}); my ($GccV1, $GccV2) = ($In::ABI{1}{"GccVersion"}, $In::ABI{2}{"GccVersion"}); my ($ClangV1, $ClangV2) = ($In::ABI{1}{"ClangVersion"}, $In::ABI{2}{"ClangVersion"}); @@ -6717,7 +6751,7 @@ $Problem_Summary = "<problem_summary>\n".$Problem_Summary."</problem_summary>\n\n"; - return ($TestInfo.$TestResults.$Problem_Summary, ""); + return ($TestInfo.$TestResults.$Problem_Summary, "", $AnyChanged); } else { # HTML @@ -6950,7 +6984,7 @@ $META_DATA .= "tool_version:$TOOL_VERSION"; $Problem_Summary .= "</table>\n"; - return ($TestInfo.$TestResults.$Problem_Summary, $META_DATA); + return ($TestInfo.$TestResults.$Problem_Summary, $META_DATA, $AnyChanged); } } @@ -8340,7 +8374,7 @@ else { my $Report = "<report kind=\"".lc($Level)."\" version=\"$XML_REPORT_VERSION\">\n\n"; - my ($Summary, $MetaData) = getSummary($Level); + my ($Summary, $MetaData, $AnyChanged) = getSummary($Level); $Report .= $Summary."\n"; $Report .= getReportProblems_All($Level); $Report .= "</report>\n"; @@ -8358,9 +8392,9 @@ my $Title = $In::Opt{"TargetTitle"}.": ".$In::Desc{1}{"Version"}." to ".$In::Desc{2}{"Version"}." compatibility report"; my $Keywords = $In::Opt{"TargetTitle"}.", compatibility, API, ABI, report"; my $Des = "API/ABI compatibility report for the ".$In::Opt{"TargetTitle"}." ".$In::Opt{"TargetComponent"}." between ".$In::Desc{1}{"Version"}." and ".$In::Desc{2}{"Version"}." versions"; - my ($BSummary, $BMetaData) = getSummary("Binary"); - my ($SSummary, $SMetaData) = getSummary("Source"); - my $Report = "<!-\- $BMetaData -\->\n<!-\- $SMetaData -\->\n".composeHTML_Head($Title, $Keywords, $Des, $CssStyles, $JScripts)."<body><a name='Source'></a><a name='Binary'></a><a name='Top'></a>"; + my ($BSummary, $BMetaData, $BAnyChanged) = getSummary("Binary"); + my ($SSummary, $SMetaData, $SAnyChanged) = getSummary("Source"); + my $Report = "<!-\- $BMetaData -\->\n<!-\- $SMetaData -\->\n".composeHTML_Head($Title, $Keywords, $Des, $CssStyles, $JScripts, ($BAnyChanged or $SAnyChanged))."<body><a name='Source'></a><a name='Binary'></a><a name='Top'></a>"; $Report .= getReportTitle("Join")." <br/> <div class='tabset'> @@ -8375,7 +8409,7 @@ } else { - my ($Summary, $MetaData) = getSummary($Level); + my ($Summary, $MetaData, $AnyChanged) = getSummary($Level); my $Title = $In::Opt{"TargetTitle"}.": ".$In::Desc{1}{"Version"}." to ".$In::Desc{2}{"Version"}." ".lc($Level)." compatibility report"; my $Keywords = $In::Opt{"TargetTitle"}.", ".lc($Level)." compatibility, API, report"; my $Des = "$Level compatibility report for the ".$In::Opt{"TargetTitle"}." ".$In::Opt{"TargetComponent"}." between ".$In::Desc{1}{"Version"}." and ".$In::Desc{2}{"Version"}." versions"; @@ -8385,7 +8419,7 @@ $Des .= " on ".showArch($In::ABI{1}{"Arch"}); } } - my $Report = "<!-\- $MetaData -\->\n".composeHTML_Head($Title, $Keywords, $Des, $CssStyles, $JScripts)."\n<body>\n<div><a name='Top'></a>\n"; + my $Report = "<!-\- $MetaData -\->\n".composeHTML_Head($Title, $Keywords, $Des, $CssStyles, $JScripts, $AnyChanged)."\n<body>\n<div><a name='Top'></a>\n"; $Report .= getReportTitle($Level)."\n".$Summary."\n"; $Report .= getReportProblems_All($Level); $Report .= getSourceInfo(); @@ -8488,9 +8522,9 @@ return $Report; } -sub composeHTML_Head($$$$$) +sub composeHTML_Head($$$$$$) { - my ($Title, $Keywords, $Des, $Styles, $Scripts) = @_; + my ($Title, $Keywords, $Des, $Styles, $Scripts, $AnyChanged) = @_; my $Head = "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n"; $Head .= "<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"en\" lang=\"en\">\n"; @@ -8498,6 +8532,11 @@ $Head .= "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n"; $Head .= "<meta name=\"keywords\" content=\"$Keywords\" />\n"; $Head .= "<meta name=\"description\" content=\"$Des\" />\n"; + + if(not $AnyChanged) { + $Head .= "<meta name=\"robots\" content=\"noindex\" />\n"; + } + $Head .= "<title>$Title</title>\n"; $Head .= "<style type=\"text/css\">\n$Styles</style>\n"; $Head .= "<script type=\"text/javascript\" language=\"JavaScript\">\n<!--\n$Scripts\n-->\n</script>\n"; @@ -8955,7 +8994,7 @@ my $Title = "$LName: public symbols"; my $Keywords = "$LName, API, symbols"; my $Des = "List of symbols in $LName ($LVersion) on ".showArch($ArchName); - $SYMBOLS_LIST = composeHTML_Head($Title, $Keywords, $Des, $CssStyles, $JScripts)." + $SYMBOLS_LIST = composeHTML_Head($Title, $Keywords, $Des, $CssStyles, $JScripts, 1)." <body><div>\n$SYMBOLS_LIST</div> <br/><br/>\n".getReportFooter()." </body></html>"; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/abi-compliance-checker-2.0/doc/Changelog.html new/abi-compliance-checker-2.1/doc/Changelog.html --- old/abi-compliance-checker-2.0/doc/Changelog.html 2017-01-28 17:20:49.000000000 +0100 +++ new/abi-compliance-checker-2.1/doc/Changelog.html 2017-06-17 06:59:27.000000000 +0200 @@ -44,6 +44,45 @@ <p/> <br/> +<b>Version 2.1 (June 17, 2017)</b><br/> +<b>Improvements</b> +<ul> + <li> + Show added v-table symbols for public classes + </li> +</ul> +<b>Bug Fixes</b> +<ul> + <li> + Fixed analysis of static methods + </li> + <li> + Fixed analysis of typedefs + </li> + <li> + Fixed analysis of zero-size structs + </li> + <li> + Fixed logs + </li> + <li> + Fixed analysis of static libraries on Windows + </li> + <li> + Fixed search for files on Windows + </li> +</ul> +<b>Other</b> +<ul> + <li> + Documented -skip-internal-types option in -help + </li> + <li> + Add noindex meta tag to report if no changes detected + </li> +</ul> +<br/> + <b>Version 2.0 (January 28, 2017)</b><br/> <b>Improvements</b> <ul> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/abi-compliance-checker-2.0/modules/Internals/ABIDump.pm new/abi-compliance-checker-2.1/modules/Internals/ABIDump.pm --- old/abi-compliance-checker-2.0/modules/Internals/ABIDump.pm 2017-01-28 17:20:49.000000000 +0100 +++ new/abi-compliance-checker-2.1/modules/Internals/ABIDump.pm 2017-06-17 06:59:27.000000000 +0200 @@ -390,8 +390,17 @@ while(<LIB>) { my $Symbol = undef; - if(not $In::Opt{"UseStaticLibs"}) + if($In::Opt{"UseStaticLibs"}) { + if(/\A\s{10,}(\d+\s+|)([_\w\?\@]+)(\s*\Z|\s+)/i) + { + # 16 IID_ISecurityInformation + # ??_7TestBaseClass@api@@6B@ (const api::TestBaseClass::`vftable') + $Symbol = $2; + } + } + else + { # Dll # 1197 4AC 0000A620 SetThreadStackGuarantee # 1198 4AD SetThreadToken (forwarded to ...) # 3368 _o2i_ECPublicKey @@ -403,14 +412,6 @@ $Symbol = $1; } } - else - { # static - if(/\A\s{10,}\d*\s+([\w\?\@]+)\s*\Z/i) - { - # 16 IID_ISecurityInformation - $Symbol = $1; - } - } if($Symbol) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/abi-compliance-checker-2.0/modules/Internals/Filter.pm new/abi-compliance-checker-2.1/modules/Internals/Filter.pm --- old/abi-compliance-checker-2.0/modules/Internals/Filter.pm 2017-01-28 17:20:49.000000000 +0100 +++ new/abi-compliance-checker-2.1/modules/Internals/Filter.pm 2017-06-17 06:59:27.000000000 +0200 @@ -148,8 +148,8 @@ if($Level eq "Binary") { if($SInfo->{"InLine"} - or isInLineInst($SInfo, $LVer)) - { + or (not $SInfo->{"Static"} and isInLineInst($SInfo, $LVer))) + { # example: _ZN6Givaro6ZpzDomINS_7IntegerEE3EndEv is not exported (inlined) if($ClassId and $SInfo->{"Virt"}) { # inline virtual methods if($Type=~/InlineVirt/) { @@ -653,7 +653,8 @@ sub isOpaque($) { my $T = $_[0]; - if(not defined $T->{"Memb"}) + if(not defined $T->{"Memb"} + and not defined $T->{"Size"}) { return 1; } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/abi-compliance-checker-2.0/modules/Internals/SysCheck.pm new/abi-compliance-checker-2.1/modules/Internals/SysCheck.pm --- old/abi-compliance-checker-2.0/modules/Internals/SysCheck.pm 2017-01-28 17:20:49.000000000 +0100 +++ new/abi-compliance-checker-2.1/modules/Internals/SysCheck.pm 2017-06-17 06:59:27.000000000 +0200 @@ -505,7 +505,7 @@ $Diff = "<table width='100%' cellpadding='0' cellspacing='0'><tr><td>$Diff</td></tr></table>"; - $Diff = composeHTML_Head($Title, $Keywords, $Description, $Styles, "")."\n<body>\n$Diff\n</body>\n</html>\n"; + $Diff = composeHTML_Head($Title, $Keywords, $Description, $Styles, "", 1)."\n<body>\n$Diff\n</body>\n</html>\n"; my $Output = $SYS_REPORT_PATH."/headers_diff/$LName"; writeFile($Output."/diff.html", $Diff); @@ -900,7 +900,7 @@ my $Description = "API compatibility report between $SystemName1 and $SystemName2 on ".showArch($ArchName); my $Styles = readModule("Styles", "CmpSystems.css"); - $SYS_REPORT = composeHTML_Head($Title, $Keywords, $Description, $Styles, "")."\n<body>\n<div>".$SYS_REPORT."</div>\n"; + $SYS_REPORT = composeHTML_Head($Title, $Keywords, $Description, $Styles, "", 1)."\n<body>\n<div>".$SYS_REPORT."</div>\n"; $SYS_REPORT .= "<br/><br/>\n"; $SYS_REPORT .= getReportFooter(); $SYS_REPORT .= "</body></html>\n"; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/abi-compliance-checker-2.0/modules/Internals/TUDump.pm new/abi-compliance-checker-2.1/modules/Internals/TUDump.pm --- old/abi-compliance-checker-2.0/modules/Internals/TUDump.pm 2017-01-28 17:20:49.000000000 +0100 +++ new/abi-compliance-checker-2.1/modules/Internals/TUDump.pm 2017-06-17 06:59:27.000000000 +0200 @@ -338,6 +338,10 @@ if(my $NSAdd = getNSAdditions($LVer, $TUnit_NameSpaces{$LVer})) { # GCC on all supported platforms does not include namespaces to the dump by default appendFile($HeaderPath, "\n // add namespaces\n".$NSAdd); + + if($HeaderPath ne $TmpHeaderPath) { + appendFile($TmpHeaderPath, "\n // add namespaces\n".$NSAdd); + } } # some GCC versions don't include class methods to the TU dump by default my ($AddClass, $ClassNum) = ("", 0); @@ -374,8 +378,13 @@ } $AddClass .= " $CName* tmp_add_class_".($ClassNum++).";\n"; } - if($AddClass) { + if($AddClass) + { appendFile($HeaderPath, "\n // add classes\n".$AddClass); + + if($HeaderPath ne $TmpHeaderPath) { + appendFile($TmpHeaderPath, "\n // add classes\n".$AddClass); + } } } writeLog($LVer, "Temporary header file \'$TmpHeaderPath\' with the following content will be compiled to create GCC translation unit dump:\n".readFile($TmpHeaderPath)."\n"); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/abi-compliance-checker-2.0/modules/Internals/Utils.pm new/abi-compliance-checker-2.1/modules/Internals/Utils.pm --- old/abi-compliance-checker-2.0/modules/Internals/Utils.pm 2017-01-28 17:20:49.000000000 +0100 +++ new/abi-compliance-checker-2.1/modules/Internals/Utils.pm 2017-06-17 06:59:27.000000000 +0200 @@ -81,7 +81,7 @@ if($In::Opt{"OS"} eq "windows") { $Path = getAbsPath($Path); - my $Cmd = "dir \"$Path\" /B /O"; + my $Cmd = "cmd /C dir \"$Path\" /B /O"; if($MaxDepth!=1) { $Cmd .= " /S"; } @@ -91,7 +91,7 @@ elsif($Type eq "f") { $Cmd .= " /A-D"; } - my @Files = split(/\n/, `$Cmd 2>\"$TmpDir/null\"`); + my @Files = split(/\n/, qx/$Cmd/); if($Name) { if(not $UseRegex) @@ -247,7 +247,7 @@ if($In::Opt{"Target"} eq "symbian") { # options for GCCE compiler - my %Symbian_Opts = map {$_=>1} ( + my @Symbian_Opts = ( "-D__GCCE__", "-DUNICODE", "-fexceptions", @@ -268,13 +268,13 @@ "-DEKA2", "-DSYMBIAN_ENABLE_SPLIT_HEADERS" ); - return join(" ", keys(%Symbian_Opts)); + return join(" ", @Symbian_Opts); } elsif($In::Opt{"OS"} eq "windows" and $In::Opt{"GccTarget"}=~/mingw/i) { # add options to MinGW compiler # to simulate the MSVC compiler - my %MinGW_Opts = map {$_=>1} ( + my @MinGW_Opts = ( "-D__unaligned=\" \"", "-D__nullptr=\"nullptr\"", "-D_WIN32", @@ -319,24 +319,24 @@ if($In::ABI{$LVer}{"Arch"} eq "x86") { - $MinGW_Opts{"-D_X86_=300"}=1; - $MinGW_Opts{"-D_M_IX86=300"}=1; + push(@MinGW_Opts, "-D_X86_=300"); + push(@MinGW_Opts, "-D_M_IX86=300"); } elsif($In::ABI{$LVer}{"Arch"} eq "x86_64") { - $MinGW_Opts{"-D_AMD64_=300"}=1; - $MinGW_Opts{"-D_M_AMD64=300"}=1; - $MinGW_Opts{"-D_M_X64=300"}=1; + push(@MinGW_Opts, "-D_AMD64_=300"); + push(@MinGW_Opts, "-D_M_AMD64=300"); + push(@MinGW_Opts, "-D_M_X64=300"); } elsif($In::ABI{$LVer}{"Arch"} eq "ia64") { - $MinGW_Opts{"-D_IA64_=300"}=1; - $MinGW_Opts{"-D_M_IA64=300"}=1; + push(@MinGW_Opts, "-D_IA64_=300"); + push(@MinGW_Opts, "-D_M_IA64=300"); } - return join(" ", sort keys(%MinGW_Opts)); + return join(" ", @MinGW_Opts); } - return ""; + return undef; } sub uncoverTypedefs($$) @@ -361,8 +361,11 @@ foreach my $Word (keys(%Words)) { my $BaseType_Name = $In::ABI{$LVer}{"TypedefBase"}{$Word}; + next if(not $BaseType_Name); + next if($BaseType_Name=~/\b$Word\b/); next if($TypeName_New=~/\b(struct|union|enum)\s\Q$Word\E\b/); + if($BaseType_Name=~/\([\*]+\)/) { # FuncPtr if($TypeName_New=~/\Q$Word\E(.*)\Z/)