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

Makefile: Do not export CGO_CFLAGS if os is Darwin (macos) #1082

Closed
wants to merge 2 commits into from

Conversation

troy0820
Copy link
Contributor

Which issue this PR addresses:

Issue 301

Fixes #301

What this PR does / why we need it:

When trying to use make on macos x, it exports the CGO_CFLAGS and disrupts the process with an error

Test plan for issue:

make generate, make test-go all worked with success on macos x

Is there any documentation that needs to be updated for this PR?

NONE

@troy0820 troy0820 force-pushed the fix/makefile branch 3 times, most recently from a107d5a to 3082d1d Compare October 19, 2020 22:05
@m1kola
Copy link
Contributor

m1kola commented Oct 20, 2020

I have a feeling (not a verified feeling :)) that it is just a version skew. Maybe we can just install a matching version of gpgme and update macOS dev env doc explaining how to do it?


export CGO_CFLAGS=-Dgpgme_off_t=off_t
ifndef CGO_CFLAGS
ifneq ("${OS}", "Darwin")
Copy link
Contributor

@m1kola m1kola Oct 20, 2020

Choose a reason for hiding this comment

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

It should probably be something like this

UNAME_S := $(shell uname -s)
ifndef CGO_CFLAGS
ifneq ("$(shell uname -s)", "Darwin")
	CGO_CFLAGS=-Dgpgme_off_t=off_t;
endif
endif

But I don't like it: I would like to avoid having a special case if possible. See #1082 (comment)

@mjudeikis
Copy link
Contributor

E2E fails with missing flakgs. Back to drawing board @troy0820 :)

@troy0820 troy0820 closed this Oct 21, 2020
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.

unknown file type gpgme_off_t for older versions of gpgme
4 participants