adoroszlai commented on code in PR #4596:
URL: https://github.com/apache/ozone/pull/4596#discussion_r1173463983


##########
hadoop-ozone/dev-support/checks/native_check.sh:
##########
@@ -0,0 +1,54 @@
+#!/usr/bin/env bash
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+function get_rocks_native_git_sha() {
+    echo "Getting Rocks Native Git sha"
+    echo
+    # Getting the latest git hash for the ./hadoop-hdds/rocks-native directory
+    echo "git log -n 1 --format=\"%h\" ./hadoop-hdds/rocks-native"
+    ROCKS_NATIVE_GIT_SHA=$(git log -n 1 --format="%h" 
./hadoop-hdds/rocks-native)
+    echo "ROCKS_NATIVE_GIT_SHA = ${ROCKS_NATIVE_GIT_SHA}"
+    readonly ROCKS_NATIVE_GIT_SHA
+}
+
+function init_native_maven_opts() {
+    if [[ "${FORCE_NATIVE_BUILD}" == "true" ]]; then
+        NATIVE_MAVEN_OPTIONS="-Drocks_tools_native"
+    else

Review Comment:
   > please make this optional, using an environment variable as condition
   
   Native build can already be forced by running `build.sh 
-Drocks_tools_native`, we don't need a variable for that.  I meant making all 
logic related to native build be conditional, i.e. retain behavior of 
`build.sh` as of current `master`.
   
   Sorry if it was unclear.



-- 
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