Project

General

Profile

Actions

Bug #1588

closed

unneeded-internal-declaration warning in tests/main.cpp

Added by Junxiao Shi over 10 years ago. Updated over 10 years ago.

Status:
Closed
Priority:
Normal
Category:
Build
Target version:
Start date:
05/10/2014
Due date:
% Done:

100%

Estimated time:

Description

OSX 10.9 with Apple LLVM version 5.0 (clang-500.2.79)

In file included from ../tests/main.cpp:28:
In file included from /opt/local/include/boost/test/unit_test.hpp:19:
/opt/local/include/boost/test/test_tools.hpp:309:18: error: variable 'dummy_cond' is not needed and will not be emitted [-Werror,-Wunneeded-internal-declaration]
namespace { bool dummy_cond = false; }
                 ^
1 error generated.
In file included from ../tests/global-configuration.cpp:25:
In file included from ../tests/test-common.hpp:28:
In file included from /opt/local/include/boost/test/unit_test.hpp:19:
/opt/local/include/boost/test/test_tools.hpp:309:18: error: variable 'dummy_cond' is not needed and will not be emitted [-Werror,-Wunneeded-internal-declaration]
namespace { bool dummy_cond = false; }
                 ^
1 error generated.
Waf: Leaving directory `/Users/shijunxiao/code/NFD/build'
Build failed
 -> task in 'unit-tests-main' failed (exit status 1): 
    {task 4351412304: cxx main.cpp -> main.cpp.1.o}
['/usr/bin/g++', '-std=c++03', '-pedantic', '-Wall', '-Wno-long-long', '-O0', '-g3', '-fcolor-diagnostics', '-Werror', '-I/Users/shijunxiao/code/NFD/build', '-I/Users/shijunxiao/code/NFD', '-I/Users/shijunxiao/code/NFD/build/core', '-I/Users/shijunxiao/code/NFD/core', '-I/opt/local/include', '-I/usr/local/include', '../tests/main.cpp', '-c', '-o', 'tests/main.cpp.1.o']
 -> task in 'unit-tests-main' failed (exit status 1): 
    {task 4351413008: cxx global-configuration.cpp -> global-configuration.cpp.1.o}
['/usr/bin/g++', '-std=c++03', '-pedantic', '-Wall', '-Wno-long-long', '-O0', '-g3', '-fcolor-diagnostics', '-Werror', '-I/Users/shijunxiao/code/NFD/build', '-I/Users/shijunxiao/code/NFD', '-I/Users/shijunxiao/code/NFD/build/core', '-I/Users/shijunxiao/code/NFD/core', '-I/opt/local/include', '-I/usr/local/include', '../tests/global-configuration.cpp', '-c', '-o', 'tests/global-configuration.cpp.1.o']
Actions #1

Updated by Junxiao Shi over 10 years ago

  • Tracker changed from Task to Bug
Actions #2

Updated by Alex Afanasyev over 10 years ago

I haven't experienced this error on OSX 10.9 with my version of clang.

You probably should update your command-line tools and this issue will go away. The most recent version (the one I'm using on OSX 10.9) is

Apple LLVM version 5.1 (clang-503.0.40) (based on LLVM 3.4svn)

Btw. Which version of boost are you using? The one from macports?

Actions #3

Updated by Alex Afanasyev over 10 years ago

  • Assignee set to Alex Afanasyev
Actions #4

Updated by Alex Afanasyev over 10 years ago

  • Category changed from Integration Tests to Build
Actions #5

Updated by Alex Afanasyev over 10 years ago

  • Status changed from New to Resolved

Junxiao, can you check that this commit fixed the problem?

Actions #6

Updated by Junxiao Shi over 10 years ago

  • Status changed from Resolved to Feedback

As of commit b3893c99500f516d55591964a81f6bbdc26bde2c, this bug is not fixed.

[127/146] cxx: tests/daemon/mgmt/validation-common.cpp -> build/tests/daemon/mgmt/validation-common.cpp.3.o
In file included from ../tests/daemon/mgmt/validation-common.cpp:27:
In file included from /opt/local/include/boost/test/unit_test.hpp:19:
/opt/local/include/boost/test/test_tools.hpp:309:18: error: variable 'dummy_cond' is not needed and will not be emitted [-Werror,-Wunneeded-internal-declaration]
namespace { bool dummy_cond = false; }
                 ^
1 error generated.

OSX 10.9, clang-500.2.79, Boost 1.55.0 from MacPorts

Actions #7

Updated by Alex Afanasyev over 10 years ago

  • Status changed from Feedback to Code review
  • % Done changed from 0 to 100
Actions #8

Updated by Alex Afanasyev over 10 years ago

  • Status changed from Code review to Closed
Actions

Also available in: Atom PDF