forked from QubesOS/qubes-mgmt-salt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
73 lines (62 loc) · 2.32 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
# The Qubes OS Project, http://www.qubes-os.org
#
# Copyright (C) 2015 Jason Mehring <nrgaway@gmail.com>
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
_self_path := $(shell readlink -m $(dir $(abspath $(lastword $(MAKEFILE_LIST)))))
include $(_self_path)/components.conf
# This file is generated from FORMULA* by yaml-dumper in mgmt-salt builder plugin
include Makefile.vars
# This file is copied in from mgmt-salt
include Makefile.install
PYTHON ?= python3
build:
make manpages -C doc
.PHONY: install-custom
install-custom::
# Install qubesctl
@install -d -m 0755 $(DESTDIR)$(BINDIR)
@install -p -m 0755 qubesctl $(DESTDIR)$(BINDIR)
# Install /etc/salt/* and /srv/*
umask 022; cp -Tr etc $(DESTDIR)/etc
umask 022; cp -Tr srv $(DESTDIR)/srv
.PHONY: install-vm
install-vm:
install -d $(DESTDIR)/usr/lib/qubes-vm-connector/ssh-wrapper
install ssh-wrapper $(DESTDIR)/usr/lib/qubes-vm-connector/ssh-wrapper/ssh
ln -s ssh $(DESTDIR)/usr/lib/qubes-vm-connector/ssh-wrapper/scp
ln -s /bin/true $(DESTDIR)/usr/lib/qubes-vm-connector/ssh-wrapper/ssh-keygen
install -d $(DESTDIR)/etc/qubes-rpc
install qubes.SaltLinuxVM $(DESTDIR)/etc/qubes-rpc
.PHONY: install-dom0
install-dom0:
$(PYTHON) setup.py install -O1 --root $(DESTDIR)
make install -C doc
.PHONY: get-sources
get-sources: GIT_REPOS := $(addprefix $(SRC_DIR)/,$(MGMT_SALT_COMPONENTS) mgmt-salt-app-saltstack)
get-sources:
@set -a; \
pushd $(BUILDER_DIR) &> /dev/null; \
SCRIPT_DIR=$(BUILDER_DIR)/scripts; \
SRC_ROOT=$(BUILDER_DIR)/$(SRC_DIR); \
for REPO in $(GIT_REPOS); do \
if [ ! -d $$REPO ]; then \
$$SCRIPT_DIR/get-sources || exit 1; \
fi; \
done; \
popd &> /dev/null
.PHONY: verify-sources
verify-sources:
@true