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

WIFEXITED missing from MinGW/MSYS2, added defines #2609

Merged
merged 2 commits into from Oct 27, 2020

Conversation

thebrave
Copy link
Contributor

Following on #2353, I'm creating a pull request to add W* defines that are missing on MinGW/MSYS2.
I don't think tests can be run on MSYS2/MinGW (perl runner prerequisites can't be installed), but I did a manual check by verilating a simple design.

Copy link
Member

@wsnyder wsnyder left a comment

Choose a reason for hiding this comment

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

Thanks for contributing these fixes.

Are you sure there isn't some other include with the proper definitions?

If not, is the pointer stuff required? On Linux's /usr/include/waitstatus.h after removing an extra level of defines it's just e.g.

define WTERMSIG(stat) ((stat) & 0x7f)

@thebrave
Copy link
Contributor Author

I tried to import something else, but the only other hit I've got for these defines in my MSYS2 directory is from tclWinPort.h from tcl 8.6. I just copied those.

@thebrave
Copy link
Contributor Author

Found another source of that macro on Win32 in the binutils-gdb repository. Same magic numbers, but binutils is a very reputable source and they explain the how they got to those numbers by pointing at defines in Microsoft's headers.

Also removed defines we don't directly need.

@thebrave thebrave requested a review from wsnyder October 27, 2020 17:24
@wsnyder wsnyder merged commit 77ac9bf into verilator:master Oct 27, 2020
@wsnyder
Copy link
Member

wsnyder commented Oct 27, 2020

Thanks for updating, and making your first pull.

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

2 participants