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 XGetopt.h inclusion for Windows/MinGW again #1694

Closed
wants to merge 1 commit into from

Conversation

vonopr
Copy link

@vonopr vonopr commented Apr 10, 2020

Same problem as #1447.

MinGW fails to build the project unless _WIN32 is replaced with _MSC_VER.

@vonopr vonopr requested a review from WardF as a code owner April 10, 2020 09:10
@CLAassistant
Copy link

CLAassistant commented Apr 10, 2020

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Vladimir Onoprienko seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@DennisHeimbigner
Copy link
Collaborator

THis probably needs a more general check. Most
of our utilities and some of our tests use XGetOpt as
the backup when using windows.

DennisHeimbigner added a commit to DennisHeimbigner/netcdf-c that referenced this pull request May 14, 2020
The current ncgen does not properly handle very large
data sections. Apparently this is very uncommon because
it was only discovered in testing the new zarr code.

The fix required a new approach to processing data sections.
Unfortunately, the resulting ncgen is slower than before
but at least it is, I think, now correct.

The added test cases are in libnczarr, and so will
not show up until that is incorporated into master.

Note also that fortran code generation changed, but
has not been tested here.

Misc. Changes
1. Cleanup error handling in ncgen -lc and -lb output
2. Cleanup Makefiles for ncgen to remove unused code
3. Added a program, ncgen/ncdumpchunks, to print
   the data for a .nc file on a per-chunk format.
4. Made the XGetOpt change in PR Unidata#1694
   for ncdump/ncvalidator
DennisHeimbigner added a commit to DennisHeimbigner/netcdf-c that referenced this pull request May 19, 2020
Fix Issue Unidata#1725.
Replace PR Unidata#1726
Also replace PR Unidata#1694

The general problem is that under Visual Studio, we are seeing
a number of undefined reference and other scoping errors.
The reason is that the code is not properly using Visual Studio
_declspec() declarations.

The basic solution is to ensure that when compiling the code itself
one needs to ensure that _declspec(dllexport) is used. There
are several sets of macros to handle this, but they all rely
on the flag DLL_EXPORT being define when the code is compiled,
but not being defined when the code is used via a .h file.

As a test, I modified XGetOpt.c to build properly. I also
fixed the oc2 library to properly _declspec things like ocdebug.

I also made some misc. changes to get all the tests to run
if cygwin is installed (to get bash, sed, etc).

Misc. Changes:
* Put XGetOpt.c into libsrc and copy at build time
  to the other directories where it is needed.
@DennisHeimbigner
Copy link
Collaborator

THis PR should be closed without merging.

@WardF WardF closed this Jun 2, 2021
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.

4 participants