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 GHA for compilation and testing #41

Merged
merged 1 commit into from
Jul 14, 2021
Merged

add GHA for compilation and testing #41

merged 1 commit into from
Jul 14, 2021

Conversation

ocefpaf
Copy link
Member

@ocefpaf ocefpaf commented Jul 13, 2021

@efiring I may need some help on how you test this locally. We do not have a make check, right?

@efiring
Copy link
Member

efiring commented Jul 13, 2021

There is no "make check", just the gsw_check executable. It currently returns zero regardless of whether it fails or succeeds. Making it return 1 (for example) on failure requires changing

        if (gsw_error_flag)
            printf("\nYour installation of the Gibbs SeaWater (GSW) "
                "Oceanographic Toolbox has errors !\n");
        else

to

        if (gsw_error_flag)
        {
            printf("\nYour installation of the Gibbs SeaWater (GSW) "
                "Oceanographic Toolbox has errors !\n");
            return (1);
        }
        else

in gsw_check_functions.c.

@ocefpaf
Copy link
Member Author

ocefpaf commented Jul 13, 2021

I can make the changes later this week. Working on setting the compiler config up first.

@DocOtak
Copy link
Contributor

DocOtak commented Jul 13, 2021

I took a crack at having a non zero exit status in #43

If you want just cherrypick that code and stick it in this PR.

@ocefpaf
Copy link
Member Author

ocefpaf commented Jul 13, 2021

It is late for me and I'm on my phone only now. It is OK to merge your PR and I'll rebase this PR tomorrow.

Thnaks!

@efiring
Copy link
Member

efiring commented Jul 14, 2021

For Linux/OSX we need to run "make -f Makefile", not just plain "make", so that Makefile will be used instead of GNUmakefile. Or remove (or move) GNUmakefile, which is obsolete; it has features specific to its origin at SIO. It shows how to do some things that someone might want, so instead of deleting it, perhaps it should be moved to "GNUmakefile.example".

@ocefpaf ocefpaf requested a review from efiring July 14, 2021 17:22
@ocefpaf
Copy link
Member Author

ocefpaf commented Jul 14, 2021

@DocOtak and @efiring this is ready for review. I tested it by breaking the code and the CIs failed as expected. Thanks @DocOtak for #43!

PS: the Windows one is also working. I have a draft in #44

@efiring efiring merged commit 52302b1 into TEOS-10:master Jul 14, 2021
@ocefpaf ocefpaf deleted the CI branch July 14, 2021 17:30
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