-
-
Notifications
You must be signed in to change notification settings - Fork 83
/
.snapcraft.yaml
88 lines (84 loc) · 2.32 KB
/
.snapcraft.yaml
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
name: nxengine-evo
base: core20
adopt-info: metadata
grade: stable
confinement: strict
architectures:
- build-on: [amd64]
apps:
nxengine-evo:
command: usr/local/bin/nxengine-evo
command-chain: [bin/desktop-launch]
desktop: usr/local/share/applications/org.nxengine.nxengine_evo.desktop
common-id: org.nxengine.nxengine_evo
plugs:
- opengl
- unity7
- wayland
- x11
- desktop
- audio-playback
- joystick
parts:
metadata:
plugin: nil
source: .
override-pull: |
snapcraftctl pull
version="$(git describe --always | sed -e 's/-/+git/;y/-/./')"
xsltproc --stringparam "VERSION" "$version" \
--stringparam "DATE" "$(date +%Y-%m-%d)" \
platform/xdg/appdata-add-version.xslt \
platform/xdg/org.nxengine.nxengine_evo.appdata.xml \
> platform/xdg/org.nxengine.nxengine_evo-snap.appdata.xml
parse-info: [platform/xdg/org.nxengine.nxengine_evo-snap.appdata.xml]
build-packages: [xsltproc]
nxengine-evo:
plugin: cmake
source: .
build-packages:
- build-essential
- libsdl2-dev
- libsdl2-mixer-dev
- libsdl2-image-dev
- libpng-dev
- libjpeg-dev
stage-packages:
- libgl1-mesa-glx
- libglew2.1
- libglu1-mesa
- libsdl2-2.0-0
- libsdl2-mixer-2.0-0
- libsdl2-image-2.0-0
- libpulse0
override-pull: |
snapcraftctl pull
# Patch icon name/icon path in desktop file
sed -i.new 's|Icon=.*|Icon=${SNAP}/usr/local/share/icons/hicolor/256x256/apps/org.nxengine.nxengine_evo.png|g' \
platform/xdg/org.nxengine.nxengine_evo.desktop
prime:
- "-usr/local/bin/nxextract"
cavestory-extract:
plugin: nil
source: .
build-packages:
- jq
- unzip
- wget
override-build: |
# Extract and install data
export APP_ID="org.nxengine.nxengine_evo"
./build-scripts/utils/common.download-extern.sh
./build-scripts/utils/common.install-extern.sh \
"$SNAPCRAFT_PART_INSTALL/usr/local/share/nxengine" \
"$SNAPCRAFT_STAGE/usr/local/bin/nxextract"
after:
- nxengine-evo
glib-only:
plugin: make
source: https://github.com/ubuntu/snapcraft-desktop-helpers.git
source-subdir: glib-only
build-packages:
- libglib2.0-dev
stage-packages:
- libglib2.0-bin