Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/amahanna/arangodb-macos-onboard
https://github.com/amahanna/arangodb-macos-onboard
Last synced: 29 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/amahanna/arangodb-macos-onboard
- Owner: aMahanna
- Created: 2021-10-19T02:44:13.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2022-06-21T21:57:47.000Z (over 2 years ago)
- Last Synced: 2024-11-07T12:52:26.775Z (3 months ago)
- Size: 3.24 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Available via [PDF](https://github.com/aMahanna/arangodb-macos-onboard/blob/main/arangodb-macos-onboard.pdf) (Latest)
### MacOS Developer Onboard
Objective: Establish an ArangoDB dev environment with CLion.
Prerequisites
- [macOS Big Sur](https://apps.apple.com/ca/app/macos-big-sur/id1526878132?mt=12)
- [Homebrew](https://brew.sh/)
- [Xcode](https://apps.apple.com/ca/app/xcode/id497799835?mt=12)
- Command Line Tools: `xcode-select --install`
- CLion 2021.2: `brew install --cask clion`
- OpenSSL 1.1: `brew install [email protected]`
- Node 16.*: `brew install node`
- Yarn 1.22.*: `brew install yarn`
- Python 3: `brew install python3` (or `brew update && brew upgrade python3`)
- Access to [arangodb/enterprise](https://github.com/arangodb/enterprise)Clone the repositories.
```
git clone https://github.com/arangodb/arangodb
cd arangodb
git clone https://github.com/arangodb/enterprise # (if you have access)
```Open CLion. From its start menu, import the `arangodb` repository via the "Open" button:
Follow through the setup Wizard.
**Note:** You _can_ click on the `Use CMakeLists.txt` checkbox during one of the Wizard steps:From the CLion preferences menu (⌘ ,):
1. Navigate to `Build, Execution, Deployment` --> `CMake`
2. Disable the Debug profile
3. Create a new profile (⌘N) with the following values:
1. Name: `RelWithDebInfo`
2. Build type: `RelWithDebInfo`
3. Toolchain: `Use: Default`
4. CMake options: ```-DCMAKE_OSX_DEPLOYMENT_TARGET= -DCMAKE_BUILD_TYPE=RelWithDebInfo -DUSE_MAINTAINER_MODE=On -DUSE_FAILURE_TESTS=On -DUSE_ENTERPRISE= -DUSE_JEMALLOC=Off -DOPENSSL_USE_STATIC_LIBS=On -DCMAKE_LIBRARY_PATH=/usr/local/Cellar//lib -DOPENSSL_ROOT_DIR=/usr/local/Cellar/ -DUSE_CCACHE=Off```
5. Build directory: `build`
6. Build options: `-j 12`
4. **Note:** Make sure to click on `Apply` or `OK` before exiting the Preferences menuAfter saving these preferences, you should see a CMake process running. Wait for it to output `[Finished]`
If no CMake Process appeared:
1. Open the CMake tab (see the toolbar containing tabs such as `Git`, `TODO`, & `Terminal`)
2. Click on the Settings Wheel --> Reset Cache and Reload ProjectThis would be a good place to restart the IDE if you have any doubts.
With the `arangodb` configuration selected (see the dropdown in the top toolbar), build the project (⌘F9):
Common errors for first-time-builds:
1. `TypeError: cannot use a string pattern on a bytes-like object` (happens at around the 33% build mark)
1. **Fix**: Replace all instances of `r'` with `rb'` in the `ExecFilterLibtool` function in `3rdParty/V8/gyp/buildtime_helpers/mac_tool.py`
2. **Reason**: Binary read must be specified for Python 3.9.7+
2. `TODO` --- Place more common errors hereRun ArangoDB via terminal with `./build/bin/arangod myDatabaseDirectory`:
Run ArangoDB via CLion by setting up the `arangodb` configuration:
1. Click on the top toolbar dropdown --> `Edit Configurations`
2. Edit the `arangodb` configuration with the following values:
1. Name: `arangodb`
2. Target: `arangodb`
3. Executable: `/arangodb/build/bin/arangod`
4. Program arguments: `myDatabaseDirectory`**At this point, you should be able to access `localhost:8529`.**