Skip to content

Commit 89edee0

Browse files
committed
cmake: eliminate a compile-time warning
In file included from /usr/include/boost/bind.hpp:30, from /usr/include/boost/property_tree/json_parser/detail/parser.hpp:7, from /usr/include/boost/property_tree/json_parser/detail/read.hpp:13, from /usr/include/boost/property_tree/json_parser.hpp:16, from /home/kdudka/git/csdiff/src/json-writer.cc:29: /usr/include/boost/bind.hpp:36:1: note: ‘#pragma message: The practice of declaring the Bind placeholders (_1, _2, ...) in the global namespace is deprecated. Please use <boost/bind/bind.hpp> + using namespace boost::placeholders, or define BOOST_BIND_GLOBAL_PLACEHOLDERS to retain the current behavior.’ 36 | BOOST_PRAGMA_MESSAGE( | ^~~~~~~~~~~~~~~~~~~~ In file included from /usr/include/boost/bind.hpp:30, from /usr/include/boost/property_tree/json_parser/detail/parser.hpp:7, from /usr/include/boost/property_tree/json_parser/detail/read.hpp:13, from /usr/include/boost/property_tree/json_parser.hpp:16, from /home/kdudka/git/csdiff/src/json-parser.cc:27: /usr/include/boost/bind.hpp:36:1: note: ‘#pragma message: The practice of declaring the Bind placeholders (_1, _2, ...) in the global namespace is deprecated. Please use <boost/bind/bind.hpp> + using namespace boost::placeholders, or define BOOST_BIND_GLOBAL_PLACEHOLDERS to retain the current behavior.’ 36 | BOOST_PRAGMA_MESSAGE( | ^~~~~~~~~~~~~~~~~~~~ This is a follow-up to csdiff-2.1.0-12-g84511fd, which did not fix the problem completely.
1 parent 8522e9f commit 89edee0

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/CMakeLists.txt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,14 @@
1717

1818
add_definitions(-Wall -Wextra -fPIC -std=c++11)
1919

20+
# eliminate the following warning:
21+
# /usr/include/boost/bind.hpp:36:1: note: ‘#pragma message: The practice
22+
# of declaring the Bind placeholders (_1, _2, ...) in the global namespace
23+
# is deprecated. Please use <boost/bind/bind.hpp> + using namespace
24+
# boost::placeholders, or define BOOST_BIND_GLOBAL_PLACEHOLDERS to retain
25+
# the current behavior.’
26+
add_definitions(-DBOOST_BIND_GLOBAL_PLACEHOLDERS)
27+
2028
# cslib.a
2129
add_library(cs STATIC
2230
abstract-filter.cc

src/pycsdiff.cc

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,6 @@
2323

2424
#include <sstream>
2525

26-
// eliminate the following warning:
27-
// /usr/include/boost/bind.hpp:36:1: note: ‘#pragma message: The practice
28-
// of declaring the Bind placeholders (_1, _2, ...) in the global namespace
29-
// is deprecated. Please use <boost/bind/bind.hpp> + using namespace
30-
// boost::placeholders, or define BOOST_BIND_GLOBAL_PLACEHOLDERS to retain
31-
// the current behavior.’
32-
#define BOOST_BIND_GLOBAL_PLACEHOLDERS
33-
3426
#include <boost/python.hpp>
3527

3628
std::string diff_scans(

0 commit comments

Comments
 (0)