Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F3765298
D2397.id6028.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D2397.id6028.diff
View Options
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
Details
Attached
Mime Type
text/plain
Expires
Sat, Nov 23, 11:35 (18 h, 43 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2257879
Default Alt Text
D2397.id6028.diff (1 KB)
Attached To
Mode
D2397: Compile darkbot only when code is updated
Attached
Detach File
Event Timeline
Log In to Comment