Skip to content
This repository was archived by the owner on Nov 20, 2023. It is now read-only.
This repository was archived by the owner on Nov 20, 2023. It is now read-only.

Compile #35

@marcinoza

Description

@marcinoza

Describe the bug
root@marcinoza:/SRC/libpredict/build# cmake -DCMAKE_INSTALL_PREFIX=/usr ..
-- Found Doxygen: /usr/bin/doxygen (found version "1.9.4") found components: doxygen dot
-- Configuring done
-- Generating done
-- Build files have been written to: /mnt/magazyn0/SRC/libpredict/build
root@marcinoza:/SRC/libpredict/build# cmake -DCMAKE_INSTALL_PREFIX=/usr ..
-- Configuring done
-- Generating done
-- Build files have been written to: /mnt/magazyn0/SRC/libpredict/build
root@marcinoza:/mnt/magazyn0/SRC/libpredict/build# make
[ 25%] Built target predict
[ 48%] Built target predict_static
[ 53%] Built target dummy-t
[ 58%] Built target link-t
[ 60%] Building CXX object tests/CMakeFiles/orbit-t.dir/testcase_reader.cpp.o
/mnt/magazyn0/SRC/libpredict/tests/testcase_reader.cpp: In function ‘std::string& ltrim(std::string&)’:
/mnt/magazyn0/SRC/libpredict/tests/testcase_reader.cpp:35:93: error: ‘std::pointer_to_unary_function<_Arg, _Result> std::ptr_fun(_Result ()(_Arg)) [with _Arg = int; _Result = int]’ is deprecated: use 'std::function' instead [-Werror=deprecated-declarations]
35 | s.erase(s.begin(), std::find_if(s.begin(), s.end(), std::not1(std::ptr_fun<int, int>(std::isspace))));
| ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
In file included from /usr/include/c++/12/string:48,
from /mnt/magazyn0/SRC/libpredict/tests/testcase_reader.h:4,
from /mnt/magazyn0/SRC/libpredict/tests/testcase_reader.cpp:1:
/usr/include/c++/12/bits/stl_function.h:1126:5: note: declared here
1126 | ptr_fun(_Result (
__x)(_Arg))
| ^~~~~~~
/mnt/magazyn0/SRC/libpredict/tests/testcase_reader.cpp:35:70: error: ‘constexpr std::unary_negate<_Predicate> std::not1(const _Predicate&) [with _Predicate = pointer_to_unary_function<int, int>]’ is deprecated: use 'std::not_fn' instead [-Werror=deprecated-declarations]
35 | s.erase(s.begin(), std::find_if(s.begin(), s.end(), std::not1(std::ptr_fun<int, int>(std::isspace))));
| ~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1046:5: note: declared here
1046 | not1(const _Predicate& __pred)
| ^~~~
/mnt/magazyn0/SRC/libpredict/tests/testcase_reader.cpp: In function ‘std::string& rtrim(std::string&)’:
/mnt/magazyn0/SRC/libpredict/tests/testcase_reader.cpp:41:84: error: ‘std::pointer_to_unary_function<_Arg, _Result> std::ptr_fun(_Result ()(_Arg)) [with _Arg = int; _Result = int]’ is deprecated: use 'std::function' instead [-Werror=deprecated-declarations]
41 | s.erase(std::find_if(s.rbegin(), s.rend(), std::not1(std::ptr_fun<int, int>(std::isspace))).base(), s.end());
| ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1126:5: note: declared here
1126 | ptr_fun(_Result (
__x)(_Arg))
| ^~~~~~~
/mnt/magazyn0/SRC/libpredict/tests/testcase_reader.cpp:41:61: error: ‘constexpr std::unary_negate<_Predicate> std::not1(const _Predicate&) [with _Predicate = pointer_to_unary_function<int, int>]’ is deprecated: use 'std::not_fn' instead [-Werror=deprecated-declarations]
41 | s.erase(std::find_if(s.rbegin(), s.rend(), std::not1(std::ptr_fun<int, int>(std::isspace))).base(), s.end());
| ~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1046:5: note: declared here
1046 | not1(const _Predicate& __pred)
| ^~~~
cc1plus: all warnings being treated as errors
make[2]: *** [tests/CMakeFiles/orbit-t.dir/build.make:90: tests/CMakeFiles/orbit-t.dir/testcase_reader.cpp.o] Błąd 1
make[1]: *** [CMakeFiles/Makefile2:314: tests/CMakeFiles/orbit-t.dir/all] Błąd 2
make: *** [Makefile:146: all] Błąd 2

To Reproduce
Steps to reproduce the behavior

Expected behavior
A description of what you expected to happen

Platform

  • Linux Ubuntu 23.04

Version
Put the version of LeanHRPT relase and development

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions