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

Add static to inline functions #1

Merged
merged 1 commit into from Aug 7, 2022
Merged

Add static to inline functions #1

merged 1 commit into from Aug 7, 2022

Conversation

ffontaine
Copy link
Contributor

This is needed to avoid a link error where the inline functions appear
missing at link time.
From c99 standard inline function should either be declared static or
have an extern instance in a c file for linking.
This fix is necessary to build with gcc 7; for some reason it was not
trigerred before.

Signed-off-by: Julien Viard de Galbert julien@vdg.name
[Retrieved from:
https://git.buildroot.net/buildroot/tree/package/dieharder/0004-Add-static-to-inline-functions.patch]
Signed-off-by: Fabrice Fontaine fontaine.fabrice@gmail.com

This is needed to avoid a link error where the inline functions appear
missing at link time.
From c99 standard inline function should either be declared static or
have an extern instance in a c file for linking.
This fix is necessary to build with gcc 7; for some reason it was not
trigerred before.

Signed-off-by: Julien Viard de Galbert <julien@vdg.name>
[Retrieved from:
https://git.buildroot.net/buildroot/tree/package/dieharder/0004-Add-static-to-inline-functions.patch]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Copy link

@marcusmueller marcusmueller left a comment

Choose a reason for hiding this comment

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

These changes are appropriate and I recommend merging them. static makes the insert symbol only visible inside the the compilation unit (i.e., dab_filltree.o) itself, otherwise I'm running into linking errors.

@eddelbuettel
Copy link
Owner

Sorry for sitting on this for so long. It's a bit of a weird situation as I act as de-factor caretaker for Dieharder.

@eddelbuettel eddelbuettel merged commit 97fc75b into eddelbuettel:master Aug 7, 2022
@marcusmueller
Copy link

Thank you for caring for this free puppy that you might not have asked for.

mbroz pushed a commit to mbroz/dieharder that referenced this pull request Jan 26, 2024
mbroz pushed a commit to mbroz/dieharder that referenced this pull request Jan 26, 2024
mbroz pushed a commit to mbroz/dieharder that referenced this pull request Jan 26, 2024
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.

None yet

3 participants