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

openmpt123: fix build on gcc-12 #8

Closed
wants to merge 1 commit into from
Closed

openmpt123: fix build on gcc-12 #8

wants to merge 1 commit into from

Conversation

trofi
Copy link

@trofi trofi commented Nov 13, 2021

gcc-12 cleaned up implicit header includes and now requires
explicit '' for 'std::unique_ptr<>':

openmpt123/openmpt123.cpp:194:14: error: 'unique_ptr' in namespace 'std' does not name a template type
  194 |         std::unique_ptr<file_audio_stream_base> impl;
      |              ^~~~~~~~~~
openmpt123/openmpt123.cpp:109:1: note: 'std::unique_ptr' is defined in header '<memory>'; did you forget to '#include <memory>'?
  108 | #include "openmpt123_waveout.hpp"
  +++ |+#include <memory>
  109 |

`gcc-12` cleaned up implicit header includes and now requires
explicit '<memory>' for 'std::unique_ptr<>':

    openmpt123/openmpt123.cpp:194:14: error: 'unique_ptr' in namespace 'std' does not name a template type
      194 |         std::unique_ptr<file_audio_stream_base> impl;
          |              ^~~~~~~~~~
    openmpt123/openmpt123.cpp:109:1: note: 'std::unique_ptr' is defined in header '<memory>'; did you forget to '#include <memory>'?
      108 | #include "openmpt123_waveout.hpp"
      +++ |+#include <memory>
      109 |
@manxorist
Copy link
Member

Thanks for the report. Applied in upstream SVN repository as https://source.openmpt.org/browse/openmpt/?op=revision&rev=15911 and backported to 0.5 as https://source.openmpt.org/browse/openmpt/?op=revision&rev=15912.

manxorist added a commit that referenced this pull request Nov 13, 2021
…required by standard and exposed by GCC 12. Fixes <#8>.

Patch-by: Sergei Trofimovich <slyich@gmail.com>


git-svn-id: https://source.openmpt.org/svn/openmpt/trunk/OpenMPT@15911 56274372-70c3-4bfc-bfc3-4c3a0b034d27
manxorist added a commit that referenced this pull request Nov 13, 2021
[Fix] openmpt123: Add missing header <memory> for std::unique_ptr as required by standard and exposed by GCC 12. Fixes <#8>.
Patch-by: Sergei Trofimovich <slyich@gmail.com>
........


git-svn-id: https://source.openmpt.org/svn/openmpt/branches/OpenMPT-1.29@15912 56274372-70c3-4bfc-bfc3-4c3a0b034d27
@manxorist manxorist closed this Nov 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants