[Debian-astro-maintainers] Bug#746988: Inconsistent use of _POSIX_SOURCE causes conflicting types

Michael Tautschnig mt at debian.org
Sun May 4 16:45:34 UTC 2014


Package: cpl-plugin-amber
Version: 4.3.1+dfsg-1
Usertags: goto-cc

During a rebuild of all packages in a clean sid chroot (and cowbuilder+pbuilder)
the build failed with the following error. Please note that we use our research
compiler tool-chain (using tools from the cbmc package), which permits extended
reporting on type inconsistencies at link time.

[...]
libtool: link: gcc -shared  -fPIC -DPIC  .libs/amberSupport.o .libs/amber_dfs.o .libs/amber_qc.o .libs/amdlibArrayGeometry.o .libs/amdlibBadPixels.o .libs/amdlibClosurePhases.o .libs/amdlibDark.o .libs/amdlibDate.o .libs/amdlibEsoUtils.o .libs/amdlibFlatField.o .libs/amdlibFrameSelection.o .libs/amdlibImagingData.o .libs/amdlibImagingDetector.o .libs/amdlibInsCfg.o .libs/amdlibLog.o .libs/amdlibMatrix.o .libs/amdlibMisc.o .libs/amdlibMultiDimArray.o .libs/amdlibOi.o .libs/amdlibOiStructures.o .libs/amdlibP2vm.o .libs/amdlibP2vmData.o .libs/amdlibPiston.o .libs/amdlibRawData.o .libs/amdlibRefSpectrum.o .libs/amdlibRegion.o .libs/amdlibScienceData.o .libs/amdlibShift.o .libs/amdlibSpectralCalibration.o .libs/amdlibSpectralCalibrationData.o .libs/amdlibSpectrum.o .libs/amdlibString.o .libs/amdlibUtils.o .libs/amdlibVisibilities.o .libs/amdlibWaveData.o .libs/amdlibYorick.o .libs/amdmsAlgo.o .libs/amdmsBadPixels.o .libs/amdmsCalibration.o .libs/amdmsCommon.o .libs/amdmsFit.o .libs/amdmsFits.o .libs/amdmsFitsCube.o .libs/amdmsFitsData.o .libs/amdmsFitsKeyword.o .libs/amdmsFitsTable.o .libs/amdmsPixelStatistics.o .libs/amdmsProperties.o .libs/esolibCalibVis.o .libs/esolibSelector.o .libs/esolibTransferfunction.o .libs/esolibamdlibOi.o .libs/gipaf.o .libs/giqclog.o   -L/usr/lib/x86_64-linux-gnu -lcpldfs -lcplui -lcplcore -lcext -lcfitsio -lfftw3 -lm -lnsl  -O2 -Wl,-z -Wl,relro   -Wl,-soname -Wl,libamber.so.0 -o .libs/libamber.so.0.0.0

error: conflicting function declarations "stat"
old definition in module amdlibArrayGeometry file /usr/include/x86_64-linux-gnu/sys/stat.h line 453
signed int (const char *__path, struct stat *__statbuf)
new definition in module amdlibFrameSelection file /usr/include/x86_64-linux-gnu/sys/stat.h line 453
signed int (const char *__path, struct stat *__statbuf)

reason for conflict at __statbuf in types listed below (struct/struct):
composite type component counts differ (18/15)
struct stat {
  unsigned long int st_dev;
  unsigned long int st_ino;
  unsigned long int st_nlink;
  unsigned int st_mode;
  unsigned int st_uid;
  unsigned int st_gid;
  signed int __pad0;
  unsigned long int st_rdev;
  signed long int st_size;
  signed long int st_blksize;
  signed long int st_blocks;
  signed long int st_atime;
  unsigned long int st_atimensec;
  signed long int st_mtime;
  unsigned long int st_mtimensec;
  signed long int st_ctime;
  unsigned long int st_ctimensec;
  signed long int [3l] __unused;
}
struct stat {
  unsigned long int st_dev;
  unsigned long int st_ino;
  unsigned long int st_nlink;
  unsigned int st_mode;
  unsigned int st_uid;
  unsigned int st_gid;
  signed int __pad0;
  unsigned long int st_rdev;
  signed long int st_size;
  signed long int st_blksize;
  signed long int st_blocks;
  struct timespec st_atim;
  struct timespec st_mtim;
  struct timespec st_ctim;
  signed long int [3l] __unused;
}

The type conflict is caused by #define _POSIX_SOURCE 1 in
amber/amdlibArrayGeometry.c -- this should be set for the entire project as a
compiler command line define or via some global config header file to ensure
type compatibility.

Best,
Michael

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 859 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/debian-astro-maintainers/attachments/20140504/01b9dd6d/attachment.sig>


More information about the Debian-astro-maintainers mailing list