Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Leftovers from #914 #944

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Leftovers from #914 #944

wants to merge 2 commits into from

Conversation

aledomu
Copy link
Contributor

@aledomu aledomu commented Oct 23, 2024

Some stuff was left from #914. Most of the commits in this new PR do not keep all the original modifications. Feel free to rearrange the commits as you see fit. I guess the one that uses std::stringstream will need to be reworked.

@x42
Copy link
Member

x42 commented Nov 6, 2024

Thanks for following up on that. I have cherry-picked all the commits except for

  1. Replace boost::aligned_storage with alignas std::array
  2. Replace boost::bind with std::bind

(1) seems that only aligns the complete buffer, but not individual type T elements

(2) fails to compile

In file included from /usr/include/boost/property_tree/json_parser/detail/read.hpp:13,
                 from /usr/include/boost/property_tree/json_parser.hpp:16,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/boost/property_tree/json_parser/detail/parser.hpp: In member function ‘void boost::property_tree::json_parser::detail::string_callback_adapter<Callbacks, Encoding, Iterator, std::input_iterator_tag>::process_codepoint(Sentinel, EncodingErrorFn)’:
/usr/include/boost/property_tree/json_parser/detail/parser.hpp:217:52: error: ‘_1’ was not declared in this scope
  217 |                             boost::ref(callbacks), _1),
      |                                                    ^~
/usr/include/boost/property_tree/json_parser/detail/parser.hpp:217:52: note: suggested alternatives:
In file included from /usr/include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from /usr/include/boost/mpl/placeholders.hpp:43,
                 from /usr/include/boost/mpl/apply.hpp:24,
                 from /usr/include/boost/mpl/aux_/iter_apply.hpp:17,
                 from /usr/include/boost/mpl/aux_/find_if_pred.hpp:14,
                 from /usr/include/boost/mpl/find_if.hpp:17,
                 from /usr/include/boost/mpl/find.hpp:17,
                 from /usr/include/boost/mpl/aux_/contains_impl.hpp:20,
                 from /usr/include/boost/mpl/contains.hpp:20,
                 from /usr/include/boost/multi_index_container.hpp:26,
                 from /usr/include/boost/property_tree/ptree.hpp:21,
                 from /usr/include/boost/property_tree/json_parser.hpp:14,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note:   ‘mpl_::_1’

There are likely some similar issues where remaining boost includes cause conflicts,

@aledomu aledomu force-pushed the remove-boost branch 2 times, most recently from 5afcb9b to 12c78ef Compare November 10, 2024 09:19
@x42
Copy link
Member

x42 commented Nov 12, 2024

This still fails to compile here after re-configuring with -DBOOST_BIND_NO_PLACEHOLDERS

[ 823/1876] Compiling libs/ardour/ffmpegfileimportable.cc
In file included from /usr/include/boost/property_tree/json_parser/detail/read.hpp:13,
                 from /usr/include/boost/property_tree/json_parser.hpp:16,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/boost/property_tree/json_parser/detail/parser.hpp: In member function ‘void boost::property_tree::json_parser::detail::string_callback_adapter<Callbacks, Encoding, Iterator, std::input_iterator_tag>::process_codepoint(Sentinel, EncodingErrorFn)’:
/usr/include/boost/property_tree/json_parser/detail/parser.hpp:217:52: error: ‘_1’ was not declared in this scope
  217 |                             boost::ref(callbacks), _1),
      |                                                    ^~
/usr/include/boost/property_tree/json_parser/detail/parser.hpp:217:52: note: suggested alternatives:
In file included from /usr/include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from /usr/include/boost/mpl/placeholders.hpp:43,
                 from /usr/include/boost/mpl/apply.hpp:24,
                 from /usr/include/boost/mpl/aux_/iter_apply.hpp:17,
                 from /usr/include/boost/mpl/aux_/find_if_pred.hpp:14,
                 from /usr/include/boost/mpl/find_if.hpp:17,
                 from /usr/include/boost/mpl/find.hpp:17,
                 from /usr/include/boost/mpl/aux_/contains_impl.hpp:20,
                 from /usr/include/boost/mpl/contains.hpp:20,
                 from /usr/include/boost/multi_index_container.hpp:26,
                 from /usr/include/boost/property_tree/ptree.hpp:21,
                 from /usr/include/boost/property_tree/json_parser.hpp:14,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note:   ‘mpl_::_1’
   29 | typedef arg<1> _1;
      |                ^~
In file included from /usr/include/boost/property_tree/ptree_fwd.hpp:17,
                 from /usr/include/boost/property_tree/ptree.hpp:15,
                 from /usr/include/boost/property_tree/json_parser.hpp:14,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/c++/10/functional:221:34: note:   ‘std::placeholders::_1’
  221 |     extern const _Placeholder<1> _1;
      |                                  ^~
In file included from /usr/include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from /usr/include/boost/mpl/placeholders.hpp:43,
                 from /usr/include/boost/mpl/apply.hpp:24,
                 from /usr/include/boost/mpl/aux_/iter_apply.hpp:17,
                 from /usr/include/boost/mpl/aux_/find_if_pred.hpp:14,
                 from /usr/include/boost/mpl/find_if.hpp:17,
                 from /usr/include/boost/mpl/find.hpp:17,
                 from /usr/include/boost/mpl/aux_/contains_impl.hpp:20,
                 from /usr/include/boost/mpl/contains.hpp:20,
                 from /usr/include/boost/multi_index_container.hpp:26,
                 from /usr/include/boost/property_tree/ptree.hpp:21,
                 from /usr/include/boost/property_tree/json_parser.hpp:14,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note:   ‘mpl_::_1’
   29 | typedef arg<1> _1;
      |                ^~
/usr/include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note:   ‘mpl_::_1’
In file included from /usr/include/boost/property_tree/json_parser/detail/read.hpp:13,
                 from /usr/include/boost/property_tree/json_parser.hpp:16,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/boost/property_tree/json_parser/detail/parser.hpp: In member function ‘void boost::property_tree::json_parser::detail::parser<Callbacks, Encoding, Iterator, Sentinel>::feed(unsigned int)’:
/usr/include/boost/property_tree/json_parser/detail/parser.hpp:520:72: error: ‘_1’ was not declared in this scope
  520 |                                                 boost::ref(callbacks), _1));
      |                                                                        ^~
/usr/include/boost/property_tree/json_parser/detail/parser.hpp:520:72: note: suggested alternatives:
In file included from /usr/include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from /usr/include/boost/mpl/placeholders.hpp:43,
                 from /usr/include/boost/mpl/apply.hpp:24,
                 from /usr/include/boost/mpl/aux_/iter_apply.hpp:17,
                 from /usr/include/boost/mpl/aux_/find_if_pred.hpp:14,
                 from /usr/include/boost/mpl/find_if.hpp:17,
                 from /usr/include/boost/mpl/find.hpp:17,
                 from /usr/include/boost/mpl/aux_/contains_impl.hpp:20,
                 from /usr/include/boost/mpl/contains.hpp:20,
                 from /usr/include/boost/multi_index_container.hpp:26,
                 from /usr/include/boost/property_tree/ptree.hpp:21,
                 from /usr/include/boost/property_tree/json_parser.hpp:14,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note:   ‘mpl_::_1’
   29 | typedef arg<1> _1;
      |                ^~
In file included from /usr/include/boost/property_tree/ptree_fwd.hpp:17,
                 from /usr/include/boost/property_tree/ptree.hpp:15,
                 from /usr/include/boost/property_tree/json_parser.hpp:14,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/c++/10/functional:221:34: note:   ‘std::placeholders::_1’
  221 |     extern const _Placeholder<1> _1;
      |                                  ^~
In file included from /usr/include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from /usr/include/boost/mpl/placeholders.hpp:43,
                 from /usr/include/boost/mpl/apply.hpp:24,
                 from /usr/include/boost/mpl/aux_/iter_apply.hpp:17,
                 from /usr/include/boost/mpl/aux_/find_if_pred.hpp:14,
                 from /usr/include/boost/mpl/find_if.hpp:17,
                 from /usr/include/boost/mpl/find.hpp:17,
                 from /usr/include/boost/mpl/aux_/contains_impl.hpp:20,
                 from /usr/include/boost/mpl/contains.hpp:20,
                 from /usr/include/boost/multi_index_container.hpp:26,
                 from /usr/include/boost/property_tree/ptree.hpp:21,
                 from /usr/include/boost/property_tree/json_parser.hpp:14,
                 from ../libs/ardour/ffmpegfileimportable.cc:19:
/usr/include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note:   ‘mpl_::_1’
   29 | typedef arg<1> _1;
      |                ^~
/usr/include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note:   ‘mpl_::_1’

Waf: Leaving directory `/home/rgareus/src/ardour/build'

@x42
Copy link
Member

x42 commented Nov 12, 2024

Maybe a bug with libboost1.74 that I'm using?

I can try with boost 1.68.0 that we use for official binaries, in the unlikely case the older version is not affected.

@aledomu
Copy link
Contributor Author

aledomu commented Nov 13, 2024

Maybe a bug with libboost1.74 that I'm using?

I can try with boost 1.68.0 that we use for official binaries, in the unlikely case the older version is not affected.

As I thought initially, it's not a buggy Boost version, just an old one. It was not up until Boost 1.85 that the property_tree module got proper support for the -DBOOST_BIND_NO_PLACEHOLDERS flag.

I just removed any flag related to boost::bind. Try if it compiles now after running ./waf configure again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants