Skip to content

Commit 62310af

Browse files
committed
docs: Address final Copilot review suggestions
Fixed two remaining issues from Copilot review: 1. **Document toolchain installation rationale** - Added detailed comment explaining why full toolchain is needed - Documents dependencies: util.sh, main.py, bootstrap/, templates/ - Clarifies this is not unnecessary bloat but required functionality 2. **Add syntax highlighting to code blocks** - Added 'bash' language identifier to all shell command blocks - Improves documentation readability - Fixed blocks at lines 62, 74, 83, 137 3. **Update environment documentation** - Removed outdated references to hardcoded compiler variables - Updated to reflect reliance on Homebrew's superenv - Clarified BOOST_INCLUDE is set in wrapper, not during build All documentation now accurately reflects the current implementation and provides proper syntax highlighting for better user experience.
1 parent ac0b77a commit 62310af

File tree

2 files changed

+19
-14
lines changed

2 files changed

+19
-14
lines changed

packaging/homebrew/HOMEBREW.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -41,25 +41,25 @@ Runtime dependencies (needed to run MFC):
4141

4242
The formula executes the following steps during installation:
4343

44-
1. Sets up environment variables for compilers and libraries
45-
2. Runs `./mfc.sh build` to compile all three binaries
46-
3. Installs binaries to Homebrew's bin directory
47-
4. Creates a wrapper script that sets up the environment
48-
5. Installs Python toolchain and examples
44+
1. Runs `./mfc.sh build` to compile all three binaries
45+
2. Installs binaries to Homebrew's bin directory
46+
3. Installs mfc.sh to libexec for script execution
47+
4. Installs Python toolchain (required for mfc.sh functionality)
48+
5. Installs examples to share directory
49+
6. Creates a wrapper script that sets up the environment
4950

5051
### Environment Configuration
5152

52-
The formula ensures proper environment setup:
53-
- BOOST_INCLUDE points to Homebrew's boost installation
54-
- FC (Fortran compiler) is set to gfortran
55-
- CC (C compiler) is set to gcc
56-
- CXX (C++ compiler) is set to g++
53+
The formula relies on Homebrew's automatic environment setup:
54+
- Compiler flags are set via the `gcc` dependency (Homebrew's superenv)
55+
- Library paths are automatically configured
56+
- The wrapper script sets BOOST_INCLUDE at runtime for user commands
5757

5858
### Wrapper Script
5959

6060
The installed `mfc` wrapper provides the complete MFC interface. It automatically configures the environment and delegates to the main `mfc.sh` script. Users can run any MFC command through this wrapper:
6161

62-
```
62+
```bash
6363
mfc build
6464
mfc run examples/case.py
6565
mfc test
@@ -71,7 +71,7 @@ mfc clean
7171
### Standard Installation
7272

7373
Users install MFC with:
74-
```
74+
```bash
7575
brew install mfc
7676
```
7777

@@ -80,7 +80,7 @@ This fetches the source tarball from GitHub releases, verifies the checksum, and
8080
### Development Installation
8181

8282
For the latest development version:
83-
```
83+
```bash
8484
brew install --HEAD mfc
8585
```
8686

@@ -134,7 +134,7 @@ Submit a pull request to homebrew-core for inclusion in the main Homebrew reposi
134134

135135
### Third-Party Tap
136136
Create a separate tap (custom repository) for immediate availability:
137-
```
137+
```bash
138138
brew tap organization/mfc
139139
brew install organization/mfc/mfc
140140
```

packaging/homebrew/mfc.rb

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ def install
3232
libexec.install "mfc.sh"
3333

3434
# Install Python toolchain
35+
# The entire toolchain directory is required because mfc.sh depends on:
36+
# - util.sh for shell utilities
37+
# - main.py and mfc/ for the Python CLI
38+
# - bootstrap/ for build/lint/format scripts
39+
# - templates/ for HPC job submission
3540
prefix.install "toolchain"
3641

3742
# Install examples

0 commit comments

Comments
 (0)