ambs/Lingua-Identify-CLD — pull request #4 by pypt (2014-03-27 15:51:06+00:00)
Title: Update code to 0.07 from CPAN; fix building with Clang

Hi Alberto,

Two changes:

1. Copied code from v0.07 on CPAN to this repository.
2. Building the module with Clang (`clang-503.0.38`, `Apple LLVM version 5.1`, `x86_64-apple-darwin13.1.0`) was failing with:

```
<...>
** Preparing XS code
cc -Icld-src -I/System/Library/Perl/5.16/darwin-thread-multi-2level/CORE -fPIC -I. -O2 -DCLD_WINDOWS -arch x86_64 -arch i386 -c -x c++ -arch x86_64 -arch i386 -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -fstack-protector -I/usr/local/include -Os -o CLD.o CLD.cc
CLD.cc:273:1: warning: duplicate 'extern' declaration specifier [-Wduplicate-decl-specifier]
XS_EXTERNAL(boot_Lingua__Identify__CLD); /* prototype to pass -Wmissing-prototypes */
^
/System/Library/Perl/5.16/darwin-thread-multi-2level/CORE/XSUB.h:145:33: note: expanded from macro 'XS_EXTERNAL'
# define XS_EXTERNAL(name) extern "C" XSPROTO(name)
^
CLD.cc:276:5: error: declaration of 'Perl___notused' has a different language linkage
dVAR; dXSARGS;
^
/System/Library/Perl/5.16/darwin-thread-multi-2level/CORE/perl.h:174:17: note: expanded from macro 'dVAR'
# define dVAR dNOOP
^
/System/Library/Perl/5.16/darwin-thread-multi-2level/CORE/perl.h:362:26: note: expanded from macro 'dNOOP'
#define dNOOP extern int Perl___notused(void)
^
CLD.cc:181:5: note: previous declaration is here
dVAR; dXSARGS;
^
/System/Library/Perl/5.16/darwin-thread-multi-2level/CORE/perl.h:174:17: note: expanded from macro 'dVAR'
# define dVAR dNOOP
^
/System/Library/Perl/5.16/darwin-thread-multi-2level/CORE/perl.h:362:26: note: expanded from macro 'dNOOP'
#define dNOOP extern int Perl___notused(void)
^
1 warning and 1 error generated.
error building CLD.o from 'CLD.cc' at /System/Library/Perl/5.16/ExtUtils/CBuilder/Base.pm line 177, line 226.
```

I've fixed it with a rather ugly hack, but everything seems to work fine.