Skip to content

Fails to build on i586 #248

@pyllyukko

Description

@pyllyukko

Hello.

I'm trying to package inspectrum 0.4.0 for SlackBuilds.org, but it fails to build on i586 arch.

You can see the build failing in this comment (you need to open the details section). It fails with the following:

/tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp: In member function ‘virtual void TracePlot::paintMid(QPainter&, QRect&, range_t<unsigned int>)’:
/tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp:35:36: error: no matching function for call to ‘max(long unsigned int, unsigned int)’
   35 |     int samplesPerColumn = std::max(1UL, sampleRange.length() / rect.width());
      |                            ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/11.2.0/algorithm:61,
                 from /usr/include/qt5/QtCore/qglobal.h:142,
                 from /usr/include/qt5/QtGui/qtguiglobal.h:43,
                 from /usr/include/qt5/QtGui/qpixmapcache.h:43,
                 from /usr/include/qt5/QtGui/QPixmapCache:1,
                 from /tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp:20:
/usr/include/c++/11.2.0/bits/stl_algobase.h:254:5: note: candidate: ‘template<class _Tp> constexpr const _Tp& std::max(const _Tp&, const _Tp&)’
  254 |     max(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/11.2.0/bits/stl_algobase.h:254:5: note:   template argument deduction/substitution failed:
/tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp:35:36: note:   deduced conflicting types for parameter ‘const _Tp’ (‘long unsigned int’ and ‘unsigned int’)
   35 |     int samplesPerColumn = std::max(1UL, sampleRange.length() / rect.width());
      |                            ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/11.2.0/algorithm:61,
                 from /usr/include/qt5/QtCore/qglobal.h:142,
                 from /usr/include/qt5/QtGui/qtguiglobal.h:43,
                 from /usr/include/qt5/QtGui/qpixmapcache.h:43,
                 from /usr/include/qt5/QtGui/QPixmapCache:1,
                 from /tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp:20:
/usr/include/c++/11.2.0/bits/stl_algobase.h:300:5: note: candidate: ‘template<class _Tp, class _Compare> constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare)’
  300 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/11.2.0/bits/stl_algobase.h:300:5: note:   template argument deduction/substitution failed:
/tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp:35:36: note:   deduced conflicting types for parameter ‘const _Tp’ (‘long unsigned int’ and ‘unsigned int’)
   35 |     int samplesPerColumn = std::max(1UL, sampleRange.length() / rect.width());
      |                            ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/11.2.0/algorithm:62,
                 from /usr/include/qt5/QtCore/qglobal.h:142,
                 from /usr/include/qt5/QtGui/qtguiglobal.h:43,
                 from /usr/include/qt5/QtGui/qpixmapcache.h:43,
                 from /usr/include/qt5/QtGui/QPixmapCache:1,
                 from /tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp:20:
/usr/include/c++/11.2.0/bits/stl_algo.h:3461:5: note: candidate: ‘template<class _Tp> constexpr _Tp std::max(std::initializer_list<_Tp>)’
 3461 |     max(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/11.2.0/bits/stl_algo.h:3461:5: note:   template argument deduction/substitution failed:
/tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp:35:36: note:   mismatched types ‘std::initializer_list<_Tp>’ and ‘long unsigned int’
   35 |     int samplesPerColumn = std::max(1UL, sampleRange.length() / rect.width());
      |                            ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/11.2.0/algorithm:62,
                 from /usr/include/qt5/QtCore/qglobal.h:142,
                 from /usr/include/qt5/QtGui/qtguiglobal.h:43,
                 from /usr/include/qt5/QtGui/qpixmapcache.h:43,
                 from /usr/include/qt5/QtGui/QPixmapCache:1,
                 from /tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp:20:
/usr/include/c++/11.2.0/bits/stl_algo.h:3467:5: note: candidate: ‘template<class _Tp, class _Compare> constexpr _Tp std::max(std::initializer_list<_Tp>, _Compare)’
 3467 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/11.2.0/bits/stl_algo.h:3467:5: note:   template argument deduction/substitution failed:
/tmp/SBo/repo.hFTEAm/build_inspectrum/inspectrum-0.4.0/src/traceplot.cpp:35:36: note:   mismatched types ‘std::initializer_list<_Tp>’ and ‘long unsigned int’
   35 |     int samplesPerColumn = std::max(1UL, sampleRange.length() / rect.width());
      |                            ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
make[2]: *** [src/CMakeFiles/inspectrum.dir/build.make:342: src/CMakeFiles/inspectrum.dir/traceplot.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [CMakeFiles/Makefile2:126: src/CMakeFiles/inspectrum.dir/all] Error 2
make: *** [Makefile:146: all] Error 2

This might have been introduced in 7830cde (#238).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions