summaryrefslogtreecommitdiffstats
path: root/rules/scummvm.make
blob: 588f877c5a6e58f7a7ed62f55e0ff3fb03a6f4d3 (plain)
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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# -*-makefile-*-
#
# Copyright (C) 2008 by Marc Kleine-Budde <mkl@pengutronix.de>
#
# See CREDITS for details about who has contributed to this project.
#
# For further information about the PTXdist project and license conditions
# see the README file.
#

#
# We provide this package
#
PACKAGES-$(PTXCONF_SCUMMVM) += scummvm

#
# Paths and names
#
SCUMMVM_VERSION	:= 0.11.1
SCUMMVM		:= scummvm-$(SCUMMVM_VERSION)
SCUMMVM_SUFFIX	:= tar.bz2
SCUMMVM_URL	:= $(PTXCONF_SETUP_SFMIRROR)/scummvm/$(SCUMMVM).$(SCUMMVM_SUFFIX)
SCUMMVM_SOURCE	:= $(SRCDIR)/$(SCUMMVM).$(SCUMMVM_SUFFIX)
SCUMMVM_DIR	:= $(BUILDDIR)/$(SCUMMVM)

# ----------------------------------------------------------------------------
# Get
# ----------------------------------------------------------------------------

$(SCUMMVM_SOURCE):
	@$(call targetinfo)
	@$(call get, SCUMMVM)

# ----------------------------------------------------------------------------
# Prepare
# ----------------------------------------------------------------------------

SCUMMVM_PATH	:= PATH=$(CROSS_PATH)
SCUMMVM_ENV 	:= $(CROSS_ENV)

SCUMMVM_MAKEVARS := AS=$(CROSS_AS)

#
# autoconf
#
SCUMMVM_AUTOCONF := \
	--host=$(PTXCONF_GNU_TARGET) \
	--prefix=/usr

$(STATEDIR)/scummvm.prepare:
	@$(call targetinfo)
	cd $(SCUMMVM_DIR) && \
		$(SCUMMVM_PATH) $(SCUMMVM_ENV) \
		./configure $(SCUMMVM_AUTOCONF)
	@$(call touch)

# ----------------------------------------------------------------------------
# Target-Install
# ----------------------------------------------------------------------------

$(STATEDIR)/scummvm.targetinstall:
	@$(call targetinfo)

	@$(call install_init, scummvm)
	@$(call install_fixup, scummvm,PACKAGE,scummvm)
	@$(call install_fixup, scummvm,PRIORITY,optional)
	@$(call install_fixup, scummvm,VERSION,$(SCUMMVM_VERSION))
	@$(call install_fixup, scummvm,SECTION,base)
	@$(call install_fixup, scummvm,AUTHOR,"Robert Schwebel <r.schwebel@pengutronix.de>")
	@$(call install_fixup, scummvm,DEPENDS,)
	@$(call install_fixup, scummvm,DESCRIPTION,missing)

	@$(call install_copy, scummvm, 0, 0, 0755, -, /usr/bin/scummvm)

	@$(call install_copy, scummvm, 0, 0, 0644, -, /usr/share/scummvm/classic080.ini)
	@$(call install_copy, scummvm, 0, 0, 0644, -, /usr/share/scummvm/modern.ini)
	@$(call install_copy, scummvm, 0, 0, 0644, -, /usr/share/scummvm/modern.zip)

	@$(call install_finish, scummvm)

	@$(call touch)

# ----------------------------------------------------------------------------
# Clean
# ----------------------------------------------------------------------------

scummvm_clean:
	rm -rf $(STATEDIR)/scummvm.*
	rm -rf $(PKGDIR)/scummvm_*
	rm -rf $(SCUMMVM_DIR)

# vim: syntax=make