Page MenuHomeDevCentral

D2397.id6028.diff
No OneTemporary

D2397.id6028.diff

diff --git a/map.jinja b/map.jinja
--- a/map.jinja
+++ b/map.jinja
@@ -197,6 +197,15 @@
},
}, default='Debian') %}
+{% set utilities = salt['grains.filter_by']({
+ 'FreeBSD': {
+ 'gmake': 'gmake',
+ },
+ 'Debian': {
+ 'gmake': 'make',
+ },
+}, default='Debian') %}
+
{# -------------------------------------------------------------
Capabilities of OS and distributions
diff --git a/roles/shellserver/odderon/code.sls b/roles/shellserver/odderon/code.sls
--- a/roles/shellserver/odderon/code.sls
+++ b/roles/shellserver/odderon/code.sls
@@ -6,6 +6,8 @@
# License: Trivial work, not eligible to copyright
# -------------------------------------------------------------
+{% from "map.jinja" import utilities with context %}
+
darkbot_repo:
file.directory:
- name: /opt/darkbot
@@ -23,8 +25,11 @@
cmd.script:
- source: salt://roles/shellserver/odderon/files/build.sh
- args: "--with-sleep=0 --with-add=0 --with-del=0 --with-random=0"
+ - template: jinja
+ - context:
+ gmake: {{ utilities.gmake }}
- cwd: /opt/darkbot
- runas: odderon
- - require:
+ - onchanges:
- git: darkbot_repo
- unless: test -f /opt/odderon/LOCKED
diff --git a/roles/shellserver/odderon/files/build.sh b/roles/shellserver/odderon/files/build.sh
--- a/roles/shellserver/odderon/files/build.sh
+++ b/roles/shellserver/odderon/files/build.sh
@@ -22,4 +22,4 @@
cd build || exit 2
sh configure -C --prefix=$PREFIX "$@"
-make
+{{ gmake }} clean all

File Metadata

Mime Type
text/plain
Expires
Tue, Nov 26, 01:03 (4 h, 11 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2263628
Default Alt Text
D2397.id6028.diff (1 KB)

Event Timeline