Help needed to fix g++ 4.7 error [Was: Bug#667120: bowtie: ftbfs with GCC-4.7]

April 22nd, 2012 - 04:20 pm ET by Andreas Tille | Report spam
Hi,

similarly to the plink case I can not found an easy solution for this
problem.

Kind regards

Andreas.


Date: Tue, 03 Apr 2012 23:08:03 +0000
From: Matthias Klose <doko@debian.org>
To: maintonly@bugs.debian.org
Subject: Bug#667120: bowtie: ftbfs with GCC-4.7
X-Debian-PR-Message: report 667120
X-Debian-PR-Package: bowtie
X-Debian-PR-Keywords: sid wheezy
X-Debian-PR-Source: bowtie

Package: bowtie
Version: 0.12.7-1
Severity: important
Tags: sid wheezy
User: debian-gcc@lists.debian.org
Usertags: ftbfs-gcc-4.7

The package fails to build in a test rebuild on at least amd64 with
gcc-4.7/g++-4.7, but succeeds to build with gcc-4.6/g++-4.6. The
severity of this report may be raised before the wheezy release.

alphabet.h:48:3: error: 'reverseInPlace' was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]

The full build log can be found at:
http://people.debian.org/~lucas/logs/2012/03/29-clang-gcc47/unstable-gcc47/bowtie_0.12.7-1_unstable-gcc47.log
The last lines of the build log are at the end of this report.

Some hints on fixing these issues can be found at
http://gcc.gnu.org/gcc-4.7/porting_to.html

To build with GCC 4.7, either set CC=gcc-4.7 CXX=g++-4.7 explicitly,
or install the gcc, g++, gfortran, ... packages from experimental.

[...]
In file included from ebwt.h:24:0,
from ebwt_build.cpp:11:
alphabet.h: In instantiation of 'void reverseComplementInPlace(TStr&, bool) [with TStr = seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna5>, seqan::Alloc<void> >]':
hit.h:97:45: required from here
alphabet.h:48:3: error: 'reverseInPlace' was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
alphabet.h:74:20: note: 'template<class TStr> void reverseInPlace(TStr&)' declared here, later in the translation unit
In file included from SeqAn-1.1/seqan/sequence.h:57:0,
from SeqAn-1.1/seqan/index.h:27,
from ebwt_build.cpp:5:
SeqAn-1.1/seqan/sequence/string_packed.h: In instantiation of 'struct seqan::_PackedConsts<const seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> > >':
SeqAn-1.1/seqan/sequence/string_packed.h:906:131: required from 'typename seqan::Position<const seqan::Iter<TContainer, seqan::Packed<THostspec> > >::Type seqan::position(const seqan::Iter<TContainer, seqan::Packed<THostspec> >&) [with TContainer = const seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> >; THostspec = seqan::Alloc<void>; typename seqan::Position<const seqan::Iter<TContainer, seqan::Packed<THostspec> > >::Type = long unsigned int]'
SeqAn-1.1/seqan/sequence/string_packed.h:1237:40: required from 'typename seqan::Difference<seqan::Iter<TContainer, seqan::Packed<THostspec> > >::Type seqan::operator-(const seqan::Iter<TContainer, seqan::Packed<THostspec> >&, const seqan::Iter<TContainer, seqan::Packed<THostspec> >&) [with TContainer = const seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> >; THostspec = seqan::Alloc<void>; typename seqan::Difference<seqan::Iter<TContainer, seqan::Packed<THostspec> > >::Type = long int]'
SeqAn-1.1/seqan/sequence/string_base.h:181:51: required from 'typename seqan::Size<const seqan::String<TValue, TSpec> >::Type seqan::length(const seqan::String<TValue, TSpec>&) [with TValue = seqan::SimpleType<unsigned char, seqan::_Dna>; TSpec = seqan::Packed<>; typename seqan::Size<const seqan::String<TValue, TSpec> >::Type = long unsigned int]'
blockwise_sa.h:354:32: required from here
SeqAn-1.1/seqan/sequence/string_packed.h:291:2: warning: comparison between 'enum seqan::BitsPerValue<seqan::SimpleType<unsigned char, seqan::_Dna> >::<anonymous>' and 'enum seqan::BitsPerValue<unsigned int>::<anonymous>' [-Wenum-compare]
SeqAn-1.1/seqan/sequence/string_packed.h: In instantiation of 'struct seqan::_PackedConsts<seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> > >':
SeqAn-1.1/seqan/sequence/string_packed.h:731:94: required from 'typename seqan::Size<seqan::String<TValue, seqan::Packed<THostspec> > >::Type seqan::reserve(seqan::String<TValue, seqan::Packed<THostspec> >&, _TSize, seqan::Tag<TUsage>) [with TValue = seqan::SimpleType<unsigned char, seqan::_Dna>; TSpec = seqan::Alloc<void>; _TSize = long unsigned int; TExpand = seqan::TagExact_; typename seqan::Size<seqan::String<TValue, seqan::Packed<THostspec> > >::Type = long unsigned int]'
ebwt.h:3891:2: required from 'static TStr Ebwt<TStr>::join(std::vector<FileBuf*>&, std::vector<RefRecord>&, uint32_t, const RefReadInParams&, uint32_t) [with TStr = seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> >; uint32_t = unsigned int]'
ebwt_build.cpp:463:9: required from 'void driver(const string&, std::vector<std::basic_string<char> >&, const string&, bool) [with TStr = seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> >; std::string = std::basic_string<char>]'
ebwt_build.cpp:600:69: required from here
SeqAn-1.1/seqan/sequence/string_packed.h:291:2: warning: comparison between 'enum seqan::BitsPerValue<seqan::SimpleType<unsigned char, seqan::_Dna> >::<anonymous>' and 'enum seqan::BitsPerValue<unsigned int>::<anonymous>' [-Wenum-compare]
ref_read.cpp: In function 'void reverseRefRecords(const std::vector<RefRecord>&, std::vector<RefRecord>&, bool, bool)':
ref_read.cpp:195:8: warning: variable 'mergedLast' set but not used [-Wunused-but-set-variable]
ref_read.cpp: In function 'std::pair<long unsigned int, long unsigned int> fastaRefReadSizes(std::vector<FileBuf*>&, std::vector<RefRecord>&, std::vector<unsigned int>&, const RefReadInParams&, BitpairOutFileBuf*, int&)':
ref_read.cpp:243:18: warning: variable 'rpcp' set but not used [-Wunused-but-set-variable]
make[2]: *** [bowtie-build] Error 1
make[2]: Leaving directory `/??PKGBUILDDIR??'
make[1]: *** [override_dh_auto_build] Error 2
make: *** [build-arch] Error 2
dpkg-buildpackage: error: debian/rules build-arch gave error exit status 2




_______________________________________________
Debian-med-packaging mailing list
Debian-med-packaging@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-...-packaging



http://fam-tille.de


To UNSUBSCRIBE, email to debian-mentors-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: http://lists.debian.org/20120422201504.GB2212@an3as.eu
email Follow the discussionReplies 2 repliesReplies Make a reply

Replies

#1 Rodolfo García Peñas
April 22nd, 2012 - 04:50 pm ET | Report spam
On Sun, 22 Apr 2012, Andreas Tille escribió:

Hi,

similarly to the plink case I can not found an easy solution for this
problem.

Kind regards



I didn't have gcc 4.7, therefore I don't have the problem. IMO the problem is that the function "reverseInPlace" is declared after the function is used.

Is defined at line 74, but used at 48.

Probably the easiest solution is moving the block:

/// Reverse a string in-place
template <typename TStr>
static inline void reverseInPlace(TStr& s) {
typedef typename Value<TStr>::Type TVal;
size_t len = length(s);
for(size_t i = 0; i < (len>>1); i++) {
TVal tmp = s[i];
s[i] = s[len-i-1];
s[len-i-1] = tmp;
}
}

before the function reverseComplementInPlace or create a function prototype (before the line 48 too):

template <typename TStr>
static inline void reverseInPlace(TStr& s);

I hope this helps.

Saludos,
kix

Andreas.


Date: Tue, 03 Apr 2012 23:08:03 +0000
From: Matthias Klose
To:
Subject: Bug#667120: bowtie: ftbfs with GCC-4.7
X-Debian-PR-Message: report 667120
X-Debian-PR-Package: bowtie
X-Debian-PR-Keywords: sid wheezy
X-Debian-PR-Source: bowtie

Package: bowtie
Version: 0.12.7-1
Severity: important
Tags: sid wheezy
User:
Usertags: ftbfs-gcc-4.7

The package fails to build in a test rebuild on at least amd64 with
gcc-4.7/g++-4.7, but succeeds to build with gcc-4.6/g++-4.6. The
severity of this report may be raised before the wheezy release.

alphabet.h:48:3: error: 'reverseInPlace' was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]

The full build log can be found at:
http://people.debian.org/~lucas/logs/2012/03/29-clang-gcc47/unstable-gcc47/bowtie_0.12.7-1_unstable-gcc47.log
The last lines of the build log are at the end of this report.

Some hints on fixing these issues can be found at
http://gcc.gnu.org/gcc-4.7/porting_to.html

To build with GCC 4.7, either set CC=gcc-4.7 CXX=g++-4.7 explicitly,
or install the gcc, g++, gfortran, ... packages from experimental.

[...]
In file included from ebwt.h:24:0,
from ebwt_build.cpp:11:
alphabet.h: In instantiation of 'void reverseComplementInPlace(TStr&, bool) [with TStr = seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna5>, seqan::Alloc<void> >]':
hit.h:97:45: required from here
alphabet.h:48:3: error: 'reverseInPlace' was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
alphabet.h:74:20: note: 'template<class TStr> void reverseInPlace(TStr&)' declared here, later in the translation unit
In file included from SeqAn-1.1/seqan/sequence.h:57:0,
from SeqAn-1.1/seqan/index.h:27,
from ebwt_build.cpp:5:
SeqAn-1.1/seqan/sequence/string_packed.h: In instantiation of 'struct seqan::_PackedConsts<const seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> > >':
SeqAn-1.1/seqan/sequence/string_packed.h:906:131: required from 'typename seqan::Position<const seqan::Iter<TContainer, seqan::Packed<THostspec> > >::Type seqan::position(const seqan::Iter<TContainer, seqan::Packed<THostspec> >&) [with TContainer = const seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> >; THostspec = seqan::Alloc<void>; typename seqan::Position<const seqan::Iter<TContainer, seqan::Packed<THostspec> > >::Type = long unsigned int]'
SeqAn-1.1/seqan/sequence/string_packed.h:1237:40: required from 'typename seqan::Difference<seqan::Iter<TContainer, seqan::Packed<THostspec> > >::Type seqan::operator-(const seqan::Iter<TContainer, seqan::Packed<THostspec> >&, const seqan::Iter<TContainer, seqan::Packed<THostspec> >&) [with TContainer = const seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> >; THostspec = seqan::Alloc<void>; typename seqan::Difference<seqan::Iter<TContainer, seqan::Packed<THostspec> > >::Type = long int]'
SeqAn-1.1/seqan/sequence/string_base.h:181:51: required from 'typename seqan::Size<const seqan::String<TValue, TSpec> >::Type seqan::length(const seqan::String<TValue, TSpec>&) [with TValue = seqan::SimpleType<unsigned char, seqan::_Dna>; TSpec = seqan::Packed<>; typename seqan::Size<const seqan::String<TValue, TSpec> >::Type = long unsigned int]'
blockwise_sa.h:354:32: required from here
SeqAn-1.1/seqan/sequence/string_packed.h:291:2: warning: comparison between 'enum seqan::BitsPerValue<seqan::SimpleType<unsigned char, seqan::_Dna> >::<anonymous>' and 'enum seqan::BitsPerValue<unsigned int>::<anonymous>' [-Wenum-compare]
SeqAn-1.1/seqan/sequence/string_packed.h: In instantiation of 'struct seqan::_PackedConsts<seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> > >':
SeqAn-1.1/seqan/sequence/string_packed.h:731:94: required from 'typename seqan::Size<seqan::String<TValue, seqan::Packed<THostspec> > >::Type seqan::reserve(seqan::String<TValue, seqan::Packed<THostspec> >&, _TSize, seqan::Tag<TUsage>) [with TValue = seqan::SimpleType<unsigned char, seqan::_Dna>; TSpec = seqan::Alloc<void>; _TSize = long unsigned int; TExpand = seqan::TagExact_; typename seqan::Size<seqan::String<TValue, seqan::Packed<THostspec> > >::Type = long unsigned int]'
ebwt.h:3891:2: required from 'static TStr Ebwt<TStr>::join(std::vector<FileBuf*>&, std::vector<RefRecord>&, uint32_t, const RefReadInParams&, uint32_t) [with TStr = seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> >; uint32_t = unsigned int]'
ebwt_build.cpp:463:9: required from 'void driver(const string&, std::vector<std::basic_string<char> >&, const string&, bool) [with TStr = seqan::String<seqan::SimpleType<unsigned char, seqan::_Dna>, seqan::Packed<> >; std::string = std::basic_string<char>]'
ebwt_build.cpp:600:69: required from here
SeqAn-1.1/seqan/sequence/string_packed.h:291:2: warning: comparison between 'enum seqan::BitsPerValue<seqan::SimpleType<unsigned char, seqan::_Dna> >::<anonymous>' and 'enum seqan::BitsPerValue<unsigned int>::<anonymous>' [-Wenum-compare]
ref_read.cpp: In function 'void reverseRefRecords(const std::vector<RefRecord>&, std::vector<RefRecord>&, bool, bool)':
ref_read.cpp:195:8: warning: variable 'mergedLast' set but not used [-Wunused-but-set-variable]
ref_read.cpp: In function 'std::pair<long unsigned int, long unsigned int> fastaRefReadSizes(std::vector<FileBuf*>&, std::vector<RefRecord>&, std::vector<unsigned int>&, const RefReadInParams&, BitpairOutFileBuf*, int&)':
ref_read.cpp:243:18: warning: variable 'rpcp' set but not used [-Wunused-but-set-variable]
make[2]: *** [bowtie-build] Error 1
make[2]: Leaving directory `/??PKGBUILDDIR??'
make[1]: *** [override_dh_auto_build] Error 2
make: *** [build-arch] Error 2
dpkg-buildpackage: error: debian/rules build-arch gave error exit status 2




_______________________________________________
Debian-med-packaging mailing list

http://lists.alioth.debian.org/cgi-...-packaging



http://fam-tille.de


To UNSUBSCRIBE, email to
with a subject of "unsubscribe". Trouble? Contact
Archive: http://lists.debian.org/




||// //\\// Rodolfo "kix" Garcia
||\\// //\\ http://www.kix.es/


To UNSUBSCRIBE, email to
with a subject of "unsubscribe". Trouble? Contact
Archive: http://lists.debian.org/

Similar topics