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

Update developer_setup.md #501

Merged
merged 2 commits into from
Feb 7, 2023
Merged

Update developer_setup.md #501

merged 2 commits into from
Feb 7, 2023

Conversation

iv1111
Copy link
Contributor

@iv1111 iv1111 commented Jul 29, 2022

@iv1111
Copy link
Contributor Author

iv1111 commented Jul 29, 2022

FYI @agrare @jrafanie @Fryguy.

@agrare agrare requested a review from jrafanie July 29, 2022 11:27
@@ -41,6 +41,10 @@
| apt | `sudo apt -y install build-essential libffi-dev libpq-dev libxml2-dev libcurl4-openssl-dev cmake python libssh2-1-dev` |
| brew | `brew install cmake libssh2` |

**Note**: Users with MacOS running on Apple M1 CPU might need to specify location of the `Homebrew` libraries explicitly.
If build steps below fail for you then run `export LIBRARY_PATH="$LIBRARY_PATH:$(brew --prefix)/lib"`and retry the failing build step.
Copy link
Member

Choose a reason for hiding this comment

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

and retry the failing build step.

Wonder if we should move this up before the brew install steps so that people can avoid "try it, if it fails do this, then try it again"

Copy link
Member

Choose a reason for hiding this comment

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

export LIBRARY_PATH="$LIBRARY_PATH:$(brew --prefix)/lib"

If this is similar to linux then this is only a temporary solution, would users also have to add this to a mac equivalent of a .bashrc file? Otherwise would this just be lost when the close the terminal/logout/reboot?

Copy link
Member

Choose a reason for hiding this comment

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

Wonder if we should move this up before the brew install steps so that people can avoid "try it, if it fails do this, then try it again"

I'm fine with having this as a note afterwards as it is an exceptional case for now. Maybe including the "ld: library not found" error message would better" would help direct people to only apply this change if you're having such a problem. Additionally, exact error messages are what people search for so we want them to find this.

If apple CPUs become the most common mac platform for us and this is still not resolved by homebrew by then, then we can proactively make it a step to follow by default on macs.

Copy link
Member

Choose a reason for hiding this comment

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

I wonder if we could check for this in bin/install ? If the platform is Darwin check if brew is in the library path.

I imagine M1 CPUs will become the predominant Mac architecture in a few years

Copy link
Member

Choose a reason for hiding this comment

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

Note: installing the pg gem didnt work without including this export PATH=$PATH:/opt/homebrew/Cellar/postgresql@11/11.16/bin in zsh

Copy link
Member

Choose a reason for hiding this comment

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

@iv1111 did you have to update your PATH as well to install the pg gem or did you not get that far?

Copy link
Member

Choose a reason for hiding this comment

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

The more succinct version of that would be export PATH=$PATH:$(brew --prefix postgresql@11)/bin

Copy link
Contributor Author

@iv1111 iv1111 Aug 4, 2022

Choose a reason for hiding this comment

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

@iv1111 did you have to update your PATH as well to install the pg gem or did you not get that far?

I didn't have that problem (I didn't install it manually though. Just ran bin/update).

Copy link
Member

Choose a reason for hiding this comment

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

Interesting, can you run which pg_config ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@agrare The result is: /opt/homebrew/opt/postgresql@11/bin/pg_config

@iv1111 iv1111 closed this by deleting the head repository Dec 16, 2022
@iv1111 iv1111 reopened this Jan 24, 2023
@iv1111
Copy link
Contributor Author

iv1111 commented Jan 24, 2023

@Fryguy @agrare the issue is still relevant occurring on my MacOS 13.0.1 (M1 arch) during bin/setup.
I have accidentally closed this PR, reopening.

@miq-bot
Copy link
Member

miq-bot commented Jan 24, 2023

Checked commits https://github.com/iv1111/guides/compare/c20dbefc8de37527d8b1b5289fe34bd90df84536~...455e1a6d5c4a90e2a5566ea6eb7e699ea3506fbf with ruby 2.6.10, rubocop 1.28.2, haml-lint 0.35.0, and yamllint
0 files checked, 0 offenses detected
Everything looks fine. ⭐

@Fryguy Fryguy merged commit c8097d3 into ManageIQ:master Feb 7, 2023
@Fryguy
Copy link
Member

Fryguy commented Feb 7, 2023

Merging since it covers the issue at hand - we can cleanup or add more details in follow up PRs

github-actions bot pushed a commit to ManageIQ/manageiq.github.io that referenced this pull request Feb 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants