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

Fix linking asmdef.exe on DOS with newer gcc #2

Merged
merged 1 commit into from
Sep 16, 2021
Merged

Fix linking asmdef.exe on DOS with newer gcc #2

merged 1 commit into from
Sep 16, 2021

Conversation

greg-kennedy
Copy link
Contributor

Add -fgnu89-inline to Make target for asmdef.exe.

GCC versions 5+ default to a new C standard, which have different handling for inline function definitions. The previous fix in line 189 corrects building for cross-compiling; however, those platforms use the asmdef.sh script to generate asmdef.inc. MS-DOS hosts instead build a helper tool called asmdef.exe, and without this new parameter, the build process will fail with "Undefined reference to..." errors on GCC >= version 5.

Adding -fgnu89-inline fixes the linker errors and allows building with modern GCC versions.

Add `-fgnu89-inline` to Make target for `asmdef.exe`.

GCC versions 5+ default to a new C standard, which have different handling for `inline` function definitions.  The previous fix in line 189 corrects building for cross-compiling; however, those platforms use the `asmdef.sh` script to generate `asmdef.inc`.  MS-DOS hosts instead build a helper tool called `asmdef.exe`, and without this new parameter, the build process will fail with "Undefined reference to..." errors on GCC >= version 5.

Adding `-fgnu89-inline` fixes the linker errors and allows building with modern GCC versions.
@msikma
Copy link
Owner

msikma commented Sep 16, 2021

Thanks, and sorry for taking so long!

@msikma msikma merged commit ae71f21 into msikma:master Sep 16, 2021
@greg-kennedy greg-kennedy deleted the patch-1 branch September 20, 2021 06:59
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