Copilot commented on code in PR #9242:
URL: https://github.com/apache/ozone/pull/9242#discussion_r2604587899


##########
hadoop-hdds/docs/content/start/FromSource.md:
##########
@@ -66,29 +66,40 @@ mvn install:install-file -DgroupId=com.google.protobuf 
-DartifactId=protoc -Dver
 cp 
$HOME/.m2/repository/com/google/protobuf/protoc/2.5.0/protoc-2.5.0-linux-aarch_64
 
$HOME/.m2/repository/com/google/protobuf/protoc/2.5.0/protoc-2.5.0-linux-aarch_64.exe
 ```
 
-## ARM-based Apple Silicon (Apple M1 ... etc)
+## ARM-based Apple silicon (Apple M1, M2, etc.)
 
 ```bash
 # Patch protobuf 2.5.0 - this is needed for Hadoop 2 support
-PROTOBUF_VERSION="2.5.0"
 curl -LO 
https://github.com/protocolbuffers/protobuf/releases/download/v2.5.0/protobuf-2.5.0.tar.gz
 tar xzf protobuf-2.5.0.tar.gz
-pushd protobuf-${PROTOBUF_VERSION}
-
-# Open the file `src/google/protobuf/stubs/platform_macros.h` with an editor 
like vim and append the following lines after line 59 (include the #).  
-# Save the file when complete.
-
-#elif defined(__arm64__)
-#define GOOGLE_PROTOBUF_ARCH_ARM 1
-#define GOOGLE_PROTOBUF_ARCH_64_BIT 1
+pushd protobuf-2.5.0
+
+# Patch to insert arm64 macro
+patch << EOF

Review Comment:
   The `patch` command should specify which file to patch. Consider using 
`patch -p1 < EOF` instead of `patch << EOF` to ensure the patch is applied 
correctly with the proper path stripping level.
   ```suggestion
   patch -p1 <<'EOF'
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to