iwasakims commented on code in PR #1142:
URL: https://github.com/apache/bigtop/pull/1142#discussion_r1273492901


##########
bigtop_toolchain/manifests/isal.pp:
##########
@@ -0,0 +1,65 @@
+# 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.
+class bigtop_toolchain::isal {
+
+  require bigtop_toolchain::packages
+  $url = "https://github.com/intel/isa-l/archive/refs/tags/v2.29.0.tar.gz";
+
+  $isal = "v2.29.0.tar.gz"
+  $isaldir = "isa-l-2.29.0"
+
+  exec { "download isal":
+    cwd     => "/usr/src",
+    command => "/usr/bin/wget $url && mkdir -p $isaldir && /bin/tar -xvzf 
$isal -C $isaldir --strip-components=1",
+    creates => "/usr/src/$isaldir",
+  }
+
+  exec { "install isal":
+    cwd     => "/usr/src/$isaldir",
+    command => "/usr/src/$isaldir/autogen.sh && /usr/src/$isaldir/configure && 
/usr/bin/make && /usr/bin/make install",
+    require => EXEC["download isal"],
+    timeout => 3000
+  }
+
+  if ($architecture in ['aarch64', 'ppc64le']) {
+    exec { "download isal":

Review Comment:
   I got following error on Rocky Linux 8 aarch64. @lvkaihua 
   
   ```
   ...
   Debug: Automatically imported bigtop_toolchain::isal from 
bigtop_toolchain/isal into production
   Error: Evaluation Error: Error while evaluating a Resource Statement, 
Duplicate declaration: Exec[download isal] is already declared at (file: 
/home/rocky/srcs/bigtop/bigtop_toolchain/manifests/isal.pp, line: 23); cannot 
redeclare (file: /home/rocky/srcs/bigtop/bigtop_toolchain/manifests/isal.pp, 
line: 37) (file: /home/rocky/srcs/bigtop/bigtop_toolchain/manifests/isal.pp, 
line: 37, column: 5) on node ip-172-31-37-198.ap-northeast-1.compute.internal
   ```



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

Reply via email to