Bug 274432

Summary: build fails due to UINT32 ...
Product: [Applications] digikam Reporter: tropikhajma <tropikhajma>
Component: Portability-CompilationAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: caulier.gilles, rschweizer
Priority: NOR    
Version: 2.0.0   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Solaris   
Latest Commit: Version Fixed In: 2.0.0
Sentry Crash Report:

Description tropikhajma 2011-05-29 16:04:07 UTC
Version:           2.0.0 (using KDE 4.6.2) 
OS:                Solaris

on Solaris 11e/amd64, using gcc4.5.2, the build fails with the below messages

This is because the UINT* types are defined in C99, but not in the C++ standard, so they are not present on Solaris.

...
/home/test/packages/BUILD/digikam-2.0.0-beta5/i386/digikam-2.0.0-beta5/core/libs/3rdparty/libpgf/PGFtypes.h:100:2: error: 'UINT8' does not name a type
/home/test/packages/BUILD/digikam-2.0.0-beta5/i386/digikam-2.0.0-beta5/core/libs/3rdparty/libpgf/PGFtypes.h:108:2: error: 'UINT32' does not name a type
/home/test/packages/BUILD/digikam-2.0.0-beta5/i386/digikam-2.0.0-beta5/core/libs/3rdparty/libpgf/PGFtypes.h:116:2: error: 'UINT32' does not name a type
...


Reproducible: Always
Comment 1 tropikhajma 2011-05-29 20:40:13 UTC
fix:

--- /home/test/packages/BUILD/digikam-2.0.0-beta5/i386/digikam-2.0.0-beta5/core/libs/3rdparty/libpgf/PGFplatform.h.orig	2011-05-29 16:24:17.529398824 +0200
+++ /home/test/packages/BUILD/digikam-2.0.0-beta5/i386/digikam-2.0.0-beta5/core/libs/3rdparty/libpgf/PGFplatform.h	2011-05-29 17:08:06.563051231 +0200
@@ -315,6 +315,12 @@
 #define __POSIX__ 
 #endif // __APPLE__
 
+//-------------------------------------------------------------------------------
+// SOLARIS
+//-------------------------------------------------------------------------------
+#ifdef __sun
+#define __POSIX__
+#endif // SOLARIS
 
 //-------------------------------------------------------------------------------
 // LINUX / GLIBC
Comment 2 caulier.gilles 2011-06-06 10:43:24 UTC
Raphael,

I CC you to this file because patch attached touch libpgf source code, to be compiled fine under Solaris.

I will apply it on digiKam core. Please include it for next libpgf release. 

Thanks in advance

Gilles Caulier
Comment 3 caulier.gilles 2011-06-06 10:47:35 UTC
Git commit b6c8d32b1bbe34541a261bd5bcee3e68dd6ec0e7 by Gilles Caulier.
Committed on 06/06/2011 at 10:46.
Pushed by cgilles into branch 'master'.

apply patch to compile fine libpgf under SOLARIS
BUGS: 274432

M  +6    -0    libs/3rdparty/libpgf/PGFplatform.h     

http://commits.kde.org/digikam/b6c8d32b1bbe34541a261bd5bcee3e68dd6ec0e7
Comment 4 Raphael Schweizer 2011-06-06 16:03:41 UTC
Thanks. Applied to our repo.

- Raphael