Debian Bug report logs - #413432
FTBFS with GCC 4.3: 'LONG_MIN' was not declared in this scope

version graph

Package: libloki; Maintainer for libloki is Petr Baranov <petr@baranov.fi>;

Reported by: Martin Michlmayr <tbm@cyrius.com>

Date: Sun, 4 Mar 2007 23:06:02 UTC

Severity: serious

Tags: patch

Found in version 0.1.5-3

Fixed in version libloki/0.1.5-3.1

Done: Stephen Gran <sgran@debian.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Lukas Fittl <lfittl@fsfe.org>:
Bug#413432; Package libloki. Full text and rfc822 format available.

Acknowledgement sent to Martin Michlmayr <tbm@cyrius.com>:
New Bug report received and forwarded. Copy sent to Lukas Fittl <lfittl@fsfe.org>. Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: Martin Michlmayr <tbm@cyrius.com>
To: submit@bugs.debian.org
Subject: FTBFS with GCC 4.3: 'LONG_MIN' was not declared in this scope
Date: Sun, 4 Mar 2007 22:57:59 +0000
Package: libloki
Version: 0.1.5-3
Usertags: ftbfs-gcc-4.3
Tags: patch

Your package fails to build with GCC 4.3.  Version 4.3 has not been
released yet but I'm building with a snapshot in order to find errors
and give people an advance warning.  A patch for this problem is
below.

> Automatic build of libloki_0.1.5-3 on coconut0 by sbuild/ia64 0.49
...
> make[2]: Entering directory `/build/tbm/libloki-0.1.5/src'
> g++ -Wall -Wold-style-cast -Wundef -Wsign-compare -Wconversion -Wpointer-arith -pedantic -g -O2 -I../include -DNDEBUG  -c -o OrderedStatic.o OrderedStatic.cpp
> /usr/lib/gcc-snapshot/lib/gcc/ia64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_vector.h: In destructor 'std::_Vector_base<_Tp, _Alloc>::~_Vector_base() [with _Tp = Loki::Private::OrderedStaticManagerClass::Data, _Alloc = std::allocator<Loki::Private::OrderedStaticManagerClass::Data>]':
> /usr/lib/gcc-snapshot/lib/gcc/ia64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_vector.h:199:   instantiated from 'std::vector<_Tp, _Alloc>::vector(const _Alloc&) [with _Tp = Loki::Private::OrderedStaticManagerClass::Data, _Alloc = std::allocator<Loki::Private::OrderedStaticManagerClass::Data>]'
> OrderedStatic.cpp:43:   instantiated from here
> /usr/lib/gcc-snapshot/lib/gcc/ia64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_vector.h:120: warning: conversion to 'long unsigned int' from 'long int' may alter its value
> /usr/lib/gcc-snapshot/lib/gcc/ia64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/vector.tcc: In member function 'void std::vector<_Tp, _Alloc>::_M_insert_aux(__gnu_cxx::__normal_iterator<typename std::_Vector_base<_Tp, _Alloc>::_Tp_alloc_type::pointer, std::vector<_Tp, _Alloc> >, const _Tp&) [with _Tp = Loki::Private::OrderedStaticManagerClass::Data, _Alloc = std::allocator<Loki::Private::OrderedStaticManagerClass::Data>]':
> /usr/lib/gcc-snapshot/lib/gcc/ia64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_vector.h:605:   instantiated from 'void std::vector<_Tp, _Alloc>::push_back(const _Tp&) [with _Tp = Loki::Private::OrderedStaticManagerClass::Data, _Alloc = std::allocator<Loki::Private::OrderedStaticManagerClass::Data>]'
> OrderedStatic.cpp:66:   instantiated from here
> /usr/lib/gcc-snapshot/lib/gcc/ia64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/vector.tcc:295: warning: conversion to 'long unsigned int' from 'long int' may alter its value
> g++ -Wall -Wold-style-cast -Wundef -Wsign-compare -Wconversion -Wpointer-arith -pedantic -g -O2 -I../include -DNDEBUG  -c -o SafeFormat.o SafeFormat.cpp
> In file included from SafeFormat.cpp:15:
> ../include/loki/SafeFormat.h: In member function 'char* Loki::PrintfState<Device, Char>::RenderWithoutSign(long int, char*, unsigned int, bool)':
> ../include/loki/SafeFormat.h:402: error: 'LONG_MIN' was not declared in this scope
> SafeFormat.cpp: In function 'void Loki::write(FILE*, const char*, const char*)':
> SafeFormat.cpp:26: warning: conversion to 'size_t' from 'long int' may alter its value
...


--- ./include/loki/SafeFormat.h~	2007-03-04 22:43:48.000000000 +0000
+++ ./include/loki/SafeFormat.h	2007-03-04 22:44:22.000000000 +0000
@@ -21,6 +21,7 @@
 

 // $Header: /cvsroot/loki-lib/loki/include/loki/SafeFormat.h,v 1.25 2006/06/19 12:39:08 syntheticpp Exp $

 

+#include <limits.h>

 #include <cstdio>

 #include <string>

 #include <stdexcept>

--- ./src/SmallObj.cpp~	2007-03-04 22:44:56.000000000 +0000
+++ ./src/SmallObj.cpp	2007-03-04 22:45:06.000000000 +0000
@@ -18,6 +18,7 @@
 

 #include <loki/SmallObj.h>

 

+#include <limits.h>

 #include <cassert>

 #include <vector>

 #include <bitset>


-- 
Martin Michlmayr
http://www.cyrius.com/



Information forwarded to debian-bugs-dist@lists.debian.org, Lukas Fittl <lfittl@fsfe.org>:
Bug#413432; Package libloki. Full text and rfc822 format available.

Acknowledgement sent to Martin Michlmayr <tbm@cyrius.com>:
Extra info received and forwarded to list. Copy sent to Lukas Fittl <lfittl@fsfe.org>. Full text and rfc822 format available.

Message #10 received at 413432@bugs.debian.org (full text, mbox):

From: Martin Michlmayr <tbm@cyrius.com>
To: 413432@bugs.debian.org
Subject: Better patch
Date: Mon, 5 Mar 2007 12:15:35 +0000
Actually, this patch is more idiomatic:

--- include/loki/SafeFormat.h~	2007-03-05 12:09:07.000000000 +0000
+++ include/loki/SafeFormat.h	2007-03-05 12:09:16.000000000 +0000
@@ -21,6 +21,7 @@
 

 // $Header: /cvsroot/loki-lib/loki/include/loki/SafeFormat.h,v 1.25 2006/06/19 12:39:08 syntheticpp Exp $

 

+#include <climits>

 #include <cstdio>

 #include <string>

 #include <stdexcept>

--- src/SmallObj.cpp~	2007-03-05 12:09:29.000000000 +0000
+++ src/SmallObj.cpp	2007-03-05 12:09:44.000000000 +0000
@@ -18,6 +18,7 @@
 

 #include <loki/SmallObj.h>

 

+#include <climits>

 #include <cassert>

 #include <vector>

 #include <bitset>


-- 
Martin Michlmayr
http://www.cyrius.com/



Information forwarded to debian-bugs-dist@lists.debian.org, Lukas Fittl <lfittl@fsfe.org>:
Bug#413432; Package libloki. Full text and rfc822 format available.

Acknowledgement sent to Martin Michlmayr <tbm@cyrius.com>:
Extra info received and forwarded to list. Copy sent to Lukas Fittl <lfittl@fsfe.org>. Full text and rfc822 format available.

Message #15 received at 413432@bugs.debian.org (full text, mbox):

From: Martin Michlmayr <tbm@cyrius.com>
To: 413432@bugs.debian.org
Subject: Background for this bug
Date: Thu, 5 Apr 2007 09:42:55 +0200
Here is an explanation for this problem which you can forward upstream
along with the patch.

In GCC 4.3, the C++ header dependencies have been cleaned up.  The
advantage of this is that programs will compile faster.  The downside
is that you actually need to directly #include everything you use (but
you really should do this anyway, otherwise your program won't work
with any compiler other than GCC).  Some background of this can be
found at http://gcc.gnu.org/PR28080

For the maintainer: You can reproduce this problem with gcc-snapshot
(20070326-1 or higher) from unstable. (Currently not available for
i386, but for amd64, powerpc and ia64.  I hope to have i386 binaries
in the archive in ~3 weeks.)  In any case, the patch I sent is tested.

I updated the patch because I noticed there's another problem in the
test directory.  main() takes int and char ** as its argument.  GCC 4.3
will produce an error if it's different.

There is one problem I left unfixed: test/SmartPtr/main.cpp still
fails to compile because -pedantic (which you use) turns a #warning
(which is GCC specific) into an error:

(sid)17604:tbm@em64t: ..ibloki-0.1.5/test/SmartPtr] g++ -Wall -Wold-style-cast -Wundef -Wsign-compare -Wconversion -Wpointer-arith -pedantic -g -O2 -I../../include -DNDEBUG  -c -o main.o main.cpp
main.cpp:50:2: error: #warning is a GCC extension

Please tell upstream about these problems.

--- include/loki/SafeFormat.h~	2007-04-05 07:26:23.000000000 +0000
+++ include/loki/SafeFormat.h	2007-04-05 07:26:34.000000000 +0000
@@ -22,6 +22,7 @@
 // $Header: /cvsroot/loki-lib/loki/include/loki/SafeFormat.h,v 1.25 2006/06/19 12:39:08 syntheticpp Exp $

 

 #include <cstdio>

+#include <climits>

 #include <string>

 #include <stdexcept>

 #include <utility>

--- src/SmallObj.cpp~	2007-04-05 07:26:42.000000000 +0000
+++ src/SmallObj.cpp	2007-04-05 07:26:54.000000000 +0000
@@ -19,6 +19,7 @@
 #include <loki/SmallObj.h>

 

 #include <cassert>

+#include <climits>

 #include <vector>

 #include <bitset>

 

--- test/SmartPtr/main.cpp~	2007-04-05 07:33:42.000000000 +0000
+++ test/SmartPtr/main.cpp	2007-04-05 07:34:42.000000000 +0000
@@ -998,7 +998,7 @@
 

 // ----------------------------------------------------------------------------

 

-int main( unsigned int , const char * [] )

+int main( unsigned int , char * [] )

 {

 

     DoRefLinkTests();


-- 
Martin Michlmayr
http://www.cyrius.com/



Information forwarded to debian-bugs-dist@lists.debian.org, Lukas Fittl <lfittl@fsfe.org>:
Bug#413432; Package libloki. Full text and rfc822 format available.

Acknowledgement sent to Lukas Fittl <lfittl@ubuntu.com>:
Extra info received and forwarded to list. Copy sent to Lukas Fittl <lfittl@fsfe.org>. Full text and rfc822 format available.

Message #20 received at 413432@bugs.debian.org (full text, mbox):

From: Lukas Fittl <lfittl@ubuntu.com>
To: 413432@bugs.debian.org
Subject: Fixed upstream
Date: Tue, 8 May 2007 13:04:41 +0200
[Message part 1 (text/plain, inline)]
Commited the fix upstream: 
http://svn.sourceforge.net/loki-lib/?rev=823&view=rev

Debian package update to 0.1.6 with this patch applied will follow soon.

Thanks,
Lukas

-- 
Lukas Fittl <lfittl@ubuntu.com>
[Message part 2 (application/pgp-signature, inline)]

Severity set to `important' from `normal' Request was from Matthias Klose <doko@cs.tu-berlin.de> to control@bugs.debian.org. (Tue, 29 May 2007 09:30:11 GMT) Full text and rfc822 format available.

Severity set to `serious' from `important' Request was from Marc Brockschmidt <marc@marcbrockschmidt.de> to control@bugs.debian.org. (Sat, 05 Apr 2008 12:45:05 GMT) Full text and rfc822 format available.

Information forwarded to debian-bugs-dist@lists.debian.org, Lukas Fittl <lfittl@fsfe.org>:
Bug#413432; Package libloki. Full text and rfc822 format available.

Acknowledgement sent to Stephen Gran <sgran@debian.org>:
Extra info received and forwarded to list. Copy sent to Lukas Fittl <lfittl@fsfe.org>. Full text and rfc822 format available.

Message #29 received at 413432@bugs.debian.org (full text, mbox):

From: Stephen Gran <sgran@debian.org>
To: 413432@bugs.debian.org
Subject: libloki: diff for NMU version 0.1.5-3.1
Date: Sat, 5 Apr 2008 15:27:34 +0100
[Message part 1 (text/plain, inline)]
tags 413432 + patch
thanks

Hi,

Attached is the diff for my libloki 0.1.5-3.1 NMU.

Cheers,
-- 
 -----------------------------------------------------------------
|   ,''`.                                            Stephen Gran |
|  : :' :                                        sgran@debian.org |
|  `. `'                        Debian user, admin, and developer |
|    `-                                     http://www.debian.org |
 -----------------------------------------------------------------
[libloki-0.1.5-3.1-nmu.diff (text/x-diff, attachment)]
[signature.asc (application/pgp-signature, inline)]

Tags added: patch Request was from Stephen Gran <sgran@debian.org> to control@bugs.debian.org. (Sat, 05 Apr 2008 14:33:20 GMT) Full text and rfc822 format available.

Reply sent to Stephen Gran <sgran@debian.org>:
You have taken responsibility. Full text and rfc822 format available.

Notification sent to Martin Michlmayr <tbm@cyrius.com>:
Bug acknowledged by developer. Full text and rfc822 format available.

Message #36 received at 413432-close@bugs.debian.org (full text, mbox):

From: Stephen Gran <sgran@debian.org>
To: 413432-close@bugs.debian.org
Subject: Bug#413432: fixed in libloki 0.1.5-3.1
Date: Sat, 05 Apr 2008 14:32:04 +0000
Source: libloki
Source-Version: 0.1.5-3.1

We believe that the bug you reported is fixed in the latest version of
libloki, which is due to be installed in the Debian FTP archive:

libloki-dev_0.1.5-3.1_i386.deb
  to pool/main/libl/libloki/libloki-dev_0.1.5-3.1_i386.deb
libloki-doc_0.1.5-3.1_all.deb
  to pool/main/libl/libloki/libloki-doc_0.1.5-3.1_all.deb
libloki0.1.5-dbg_0.1.5-3.1_i386.deb
  to pool/main/libl/libloki/libloki0.1.5-dbg_0.1.5-3.1_i386.deb
libloki0.1.5_0.1.5-3.1_i386.deb
  to pool/main/libl/libloki/libloki0.1.5_0.1.5-3.1_i386.deb
libloki_0.1.5-3.1.diff.gz
  to pool/main/libl/libloki/libloki_0.1.5-3.1.diff.gz
libloki_0.1.5-3.1.dsc
  to pool/main/libl/libloki/libloki_0.1.5-3.1.dsc



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 413432@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Stephen Gran <sgran@debian.org> (supplier of updated libloki package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.7
Date: Sat, 05 Apr 2008 14:57:24 +0100
Source: libloki
Binary: libloki0.1.5 libloki0.1.5-dbg libloki-dev libloki-doc
Architecture: source all i386
Version: 0.1.5-3.1
Distribution: unstable
Urgency: low
Maintainer: Lukas Fittl <lfittl@fsfe.org>
Changed-By: Stephen Gran <sgran@debian.org>
Description: 
 libloki-dev - a C++ library of generic design patterns (development files)
 libloki-doc - a C++ library of generic design patterns (documentation)
 libloki0.1.5 - a C++ library of generic design patterns
 libloki0.1.5-dbg - a C++ library of generic design patterns (debug information)
Closes: 413432
Changes: 
 libloki (0.1.5-3.1) unstable; urgency=low
 .
   * Non-maintainer upload.
   * Fix FTBFS with gcc-4.3 (closes: #413432)
   * Update Standards-Version (no changes)
   * Make lintian happy:
     - Change from Source-Version to binary:Version in debian/control
     - Don't ignore errors on clean
     - Add copyright symbol to debian/copyright
     - Move Homepage: from description to control field
     - Register doc-base files with right section
Files: 
 d71f2b3a8759412bb7912bffdbeb0e5a 653 libs optional libloki_0.1.5-3.1.dsc
 a0b9add521061bfb0fbfa1e9231cd1f5 5132 libs optional libloki_0.1.5-3.1.diff.gz
 7fd5e8d210d4c84521711cba292dca39 76984 doc optional libloki-doc_0.1.5-3.1_all.deb
 b776ea8b7dd1f6e91f10107c302c3db0 19594 libs optional libloki0.1.5_0.1.5-3.1_i386.deb
 4d2264fe352e457eacaf9875f44d04e8 99898 libs extra libloki0.1.5-dbg_0.1.5-3.1_i386.deb
 0e1a5f02690f683f985a989fc46c38c3 117210 libdevel optional libloki-dev_0.1.5-3.1_i386.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFH94wzSYIMHOpZA44RAmGYAKChwwWK5acbuWtkWvKjs0KtUXJ2cQCeOyvq
nKGyFHz2fRo+mLKSM2YKgoI=
=LTW3
-----END PGP SIGNATURE-----





Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Sun, 04 May 2008 07:32:58 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Sun Apr 20 14:18:19 2014; Machine Name: beach.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.