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

pgpointcloud: respect CXX configuration variable #21440

Merged
merged 1 commit into from Nov 25, 2023

Conversation

nilason
Copy link
Contributor

@nilason nilason commented Nov 18, 2023

Description

The build does not respect the CXX variable. This PR adds a patch, which fixes this.
(The patch is submitted upstreams.)

The port's patch files are now split into separate files according to issue.

Closes https://trac.macports.org/ticket/68723

Type(s)
  • bugfix
  • enhancement
  • security fix
Tested on

macOS 13.6.2 22G320 arm64
Xcode 15.0.1 15A507

Verification

Have you

  • followed our Commit Message Guidelines?
  • squashed and minimized your commits?
  • checked that there aren't other open pull requests for the same change?
  • referenced existing tickets on Trac with full URL?
  • checked your Portfile with port lint --nitpick?
  • tried existing tests with sudo port test?
  • tried a full install with sudo port -vst install?
  • tested basic functionality of all binary files?
  • checked that the Portfile's most important variants haven't been broken?

@ryandesign
Copy link
Contributor

Great but it still doesn't respect the CXXFLAGS environment variable. Maybe adding @CXXFLAGS@ to the end of the CXXFLAGS line, mirroring the earlier CFLAGS line, is all that's needed.

In fact, it's weird that it says CFLAGS = @CFLAGS@ (meaning: any CFLAGS specified as environment variables at build time are overwritten by those that were specified at configure time, which is probably fine for a project that uses a configure script) yet it says CXXFLAGS += -fPIC -std=c++0x (meaning: any CXXFLAGS specified as environment variables at build time are appended to and any specified at configure time are ignored). They should both respect choices made at configure time, and they should both either ignore build-time environment variables or make use of them, I don't care which, it just makes no sense that the two variables are handled differently from one another.

@nilason
Copy link
Contributor Author

nilason commented Nov 18, 2023

Great but it still doesn't respect the CXXFLAGS environment variable. Maybe adding @CXXFLAGS@ to the end of the CXXFLAGS line, mirroring the earlier CFLAGS line, is all that's needed.

In fact, it's weird that it says CFLAGS = @CFLAGS@ (meaning: any CFLAGS specified as environment variables at build time are overwritten by those that were specified at configure time, which is probably fine for a project that uses a configure script) yet it says CXXFLAGS += -fPIC -std=c++0x (meaning: any CXXFLAGS specified as environment variables at build time are appended to and any specified at configure time are ignored). They should both respect choices made at configure time, and they should both either ignore build-time environment variables or make use of them, I don't care which, it just makes no sense that the two variables are handled differently from one another.

I agree that there is inconsistence, what do you think of changing to this:

CC = @CC@
CFLAGS += @CFLAGS@
CXX = @CXX@
CXXFLAGS += -fPIC -std=c++11 @CXXFLAGS@

@pmetzger
Copy link
Member

@nilason You may have to come up with a solution on your own. Ryan is often busy and doesn't have the time to respond. Let me know when you feel you have something you are comfortable committing.

@nilason
Copy link
Contributor Author

nilason commented Nov 21, 2023

@nilason You may have to come up with a solution on your own. Ryan is often busy and doesn't have the time to respond. Let me know when you feel you have something you are comfortable committing.

Thanks, will give this some more thought and ping you when the time has come.

@nilason
Copy link
Contributor Author

nilason commented Nov 21, 2023

@pmetzger Now I'm good for merge.

@reneeotten reneeotten merged commit 7fe9262 into macports:master Nov 25, 2023
3 checks passed
@nilason nilason deleted the pgpointcloud_fix_cxx branch November 27, 2023 08:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
5 participants