summaryrefslogtreecommitdiffstats
path: root/core/modules/printergui/module.build
blob: 0f335341f5a8b0074dff42f28fcf8e0a2eab7b08 (plain) (blame)
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
#!/bin/bash

fetch_source() {
	git clone "${REQUIRED_GIT}" "${MODULE_WORK_DIR}/src"
	cd "${MODULE_WORK_DIR}/src"
	git checkout "$REQUIRED_COMMIT"
	cd - &>/dev/null
}

build() {
	local SRCDIR="${MODULE_WORK_DIR}/src/"
	local DESTDIR="${MODULE_BUILD_DIR}/opt/openslx/cups"

	# first activate qt 4
	activate_qt 4

	mkdir -p "$DESTDIR"
	cd "$DESTDIR" || perror "Could not cd to $DESTDIR!"
	pinfo "Running cmake"
	cmake "$SRCDIR/" || perror "'cmake' failed (e.g. not installed)."
	pinfo "Running make"
	make || perror "'make' failed."
	chmod 0700 "$DESTDIR/printpwgui"	# So picky cupsd won't drop privileges to lp

}
post_copy() {
	:
}