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

wrap sound_init_success in #if defined(SDL_SOUND) block #76802

Merged
merged 1 commit into from
Oct 5, 2024

Conversation

HadeanLake
Copy link
Contributor

@HadeanLake HadeanLake commented Oct 3, 2024

Summary

None

Purpose of change

Resolve #76796
fix tiles no sound build
build fails because sound_init_success is declared inside #if defined(SDL_SOUND) block and then used regardless

Describe the solution

wrap sound_init_success check into #if defined(SDL_SOUND) block
( load_soundset() is empty inline function anyway if SDL_SOUND is not #defined )

Describe alternatives you've considered

Testing

Compiled with TILES=1 SOUND=0
Compiled with TILES=1 SOUND=1, checked that sound is present

Additional context

@github-actions github-actions bot added [C++] Changes (can be) made in C++. Previously named `Code` <Bugfix> This is a fix for a bug (or closes open issue) astyled astyled PR, label is assigned by github actions json-styled JSON lint passed, label assigned by github actions labels Oct 3, 2024
@HadeanLake HadeanLake marked this pull request as ready for review October 3, 2024 21:03
@github-actions github-actions bot added the BasicBuildPassed This PR builds correctly, label assigned by github actions label Oct 4, 2024
Copy link
Member

@RenechCDDA RenechCDDA left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM and Clang 12, Ubuntu, Tiles, ASan is building successfully with this PR where it wasn't before.

@Maleclypse Maleclypse merged commit 0c7aa9d into CleverRaven:master Oct 5, 2024
39 of 47 checks passed
@HadeanLake HadeanLake deleted the ifdefine branch October 5, 2024 08:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions <Bugfix> This is a fix for a bug (or closes open issue) [C++] Changes (can be) made in C++. Previously named `Code` json-styled JSON lint passed, label assigned by github actions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

tiles no sound build fails with use of undeclared identifier error
3 participants