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

define stat wrappers depending on whether symbol is found #779

Merged
merged 3 commits into from
Jul 10, 2023
Merged

Conversation

adammoody
Copy link
Collaborator

Description

Motivation and Context

How Has This Been Tested?

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Performance enhancement (non-breaking change which improves efficiency)
  • Code cleanup (non-breaking change which makes code smaller or more readable)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Testing (addition of new tests or update to current tests)
  • Documentation (a change to man pages or other documentation)

Checklist:

  • My code follows the UnifyFS code style requirements.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • All commit messages are properly formatted.

@adammoody
Copy link
Collaborator Author

@wangvsa , I'm hitting some link time errors when building on tioga due to missing symbols stat64 and fstat64. Have you tried to build there?

I'm building everything direct (no spack), which might be part of the problem. I did find that I needed to set some variables to pick up the Cray compilers instead of the system gcc: ./configure CC=cc CXX=CC .... I made some tweaks to bootstrap.sh, as well. I can pass any of that along if you're doing the same.

What's strange is that configure claims to find these functions, but then I hit the link errors when building some of the examples. I haven't tracked it down just yet. I did find there are some definitions for these in /usr/lib64/libc_nonshared.a, which maybe is where configure found them during its check.

Also, I made a few changes to some of the wrapper code. Would you please review those changes (second commit)?

@wangvsa
Copy link
Collaborator

wangvsa commented Jun 23, 2023

I just tried on Tioga and got the same link issue (I also build everything directly). Adding the conditional check doesn't seem to solve the issue, since configure was able to find stat64/fstat64. Are there any other changes you made?

@adammoody
Copy link
Collaborator Author

No, I haven't figured it out yet, but it's useful to know that it's not just me. I had some other tests to run, so I just commented out those wrappers for now as a work around.

I'm guessing it has something to do with the Cray compilers. Are you building directly or via spack?

@wangvsa
Copy link
Collaborator

wangvsa commented Jun 23, 2023

I'm building it directly (without spack). I also set CC=cc CXX=CC so that bootstrap and configure pick the cray compiler.

@MichaelBrim
Copy link
Collaborator

Not sure if it's relevant or helpful, but when I'm building from source on Crusher/Frontier I have recently needed to set CC=craycc and CXX=crayCC

Copy link
Collaborator

@MichaelBrim MichaelBrim left a comment

Choose a reason for hiding this comment

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

looks good to me

@adammoody adammoody merged commit 4f50687 into dev Jul 10, 2023
@adammoody adammoody deleted the fstat branch July 10, 2023 19:41
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.

3 participants