Makefile 7.81 KB
Newer Older
Alexander Larsson's avatar
Alexander Larsson committed
1
2
3
srcdir = $(CURDIR)
builddir = $(CURDIR)

4
5
FREEDESKTOP_VERSION=0.1
GNOME_VERSION=3.16
6
ARCH=x86_64
7
IMAGES=freedesktop-sdk-base/build/$(ARCH)/images
8
9
10
SPECS=packages/SPECS
NOARCH=packages/RPMS/noarch

11
all: gnome-platform.tar.gz gnome-sdk.tar.gz
12

13
14
15
$(IMAGES)/freedesktop-contents-sdk-$(ARCH).tar.gz $(IMAGES)/freedesktop-contents-platform-$(ARCH).tar.gz images:
	if test ! -d freedesktop-sdk-base; then \
		git clone https://github.com/alexlarsson/freedesktop-sdk-base.git;\
Alexander Larsson's avatar
Alexander Larsson committed
16
	fi
17
18
	(cd  freedesktop-sdk-base; git pull;)
	(cd  freedesktop-sdk-base; make;)
Alexander Larsson's avatar
Alexander Larsson committed
19
20
21
22

NULL=

PACKAGES = \
23
	freedesktop-platform-base freedesktop-sdk-base \
Alexander Larsson's avatar
Alexander Larsson committed
24
25
26
27
28
29
30
31
32
33
34
	gtk-doc-stub \
	glib2 \
	gnome-common \
	gobject-introspection \
	shared-mime-info \
	pixman \
	freetype \
	fontconfig \
	xorg-x11-util-macros \
	xorg-x11-proto-devel \
	libXau xcb-proto libxcb libXdmcp xorg-x11-xtrans-devel libX11 libXrender \
35
	libXfixes libXext libXft libXi libXinerama libICE libSM libXpm libXrandr libXtst libXt libXScrnSaver \
Alexander Larsson's avatar
Alexander Larsson committed
36
	libXv libXvMC libXxf86vm libXdamage libXcursor libXcomposite libxkbfile libxshmfence \
Alexander Larsson's avatar
Alexander Larsson committed
37
	xkeyboard-config libxkbcommon \
38
	SDL2 SDL2_image SDL2_net SDL2_ttf SDL2_mixer \
Alexander Larsson's avatar
Alexander Larsson committed
39
	dbus cairo dbus-glib \
40
	libpciaccess libdrm llvm mesa libepoxy wayland \
Alexander Larsson's avatar
Alexander Larsson committed
41
	pulseaudio \
42
	freedesktop-platform freedesktop-sdk \
Alexander Larsson's avatar
Alexander Larsson committed
43
	graphite2 harfbuzz libdatrie libthai pango atk at-spi2-core at-spi2-atk gdk-pixbuf2 gtk3 \
44
	libsecret \
Alexander Larsson's avatar
Alexander Larsson committed
45
	itstool yelp-xsl yelp-tools \
Alexander Larsson's avatar
Alexander Larsson committed
46
	hicolor-icon-theme libcroco vala librsvg2 adwaita-icon-theme \
Alexander Larsson's avatar
Alexander Larsson committed
47
	gnome-sdk gnome-platform dejavu-fonts abattis-cantarell-fonts \
Alexander Larsson's avatar
Alexander Larsson committed
48
	gtk2 gnome-themes-standard libproxy gsettings-desktop-schemas glib-networking libsoup \
Alexander Larsson's avatar
Add gjs    
Alexander Larsson committed
49
	dconf gvfs desktop-file-utils json-glib libnotify vte mozjs24 gjs \
50
	gstreamer1 python3-cairo pygobject3 \
Alexander Larsson's avatar
Alexander Larsson committed
51
	cogl clutter clutter-gtk webkitgtk4 \
52
	aspell hunspell-en hunspell enchant \
Alexander Larsson's avatar
Alexander Larsson committed
53
	zenity \
Alexander Larsson's avatar
Alexander Larsson committed
54
55
	$(NULL)

56
ALL_SPECS =$(PACKAGES:%=$(SPECS)/%.spec)
Alexander Larsson's avatar
Alexander Larsson committed
57
58
59

deps: rpm-dependencies.P

60
61
rpm-dependencies.P: $(ALL_SPECS) makedeps.sh $(IMAGES)/freedesktop-contents-sdk-$(ARCH).tar.gz
	./setup.sh $(IMAGES)/freedesktop-contents-sdk-$(ARCH).tar.gz
62
	./build.sh ./makedeps.sh $(ALL_SPECS) > rpm-dependencies.P
Alexander Larsson's avatar
Alexander Larsson committed
63

Alexander Larsson's avatar
Alexander Larsson committed
64
gnome-sdk.tar.gz gnome-sdk-rpmdb.tar.gz: $(NOARCH)/gnome-sdk-0.1-1.sdk.noarch.rpm
65
	./setup.sh $(IMAGES)/freedesktop-contents-sdk-$(ARCH).tar.gz
Alexander Larsson's avatar
Alexander Larsson committed
66
	./build.sh smart install -y  $(NOARCH)/gnome-sdk-0.1-1.sdk.noarch.rpm
67
	rm -rf gnome-sdk.tar.gz gnome-sdk-rpmdb.tar.gz
68
	tar --transform 's,^root/usr,files,S' -czf gnome-sdk.tar.gz root/usr --owner=root
Alexander Larsson's avatar
Alexander Larsson committed
69
	tar --transform 's,^var,files,S' -czf gnome-sdk-rpmdb.tar.gz var/lib/rpm --owner=root
Alexander Larsson's avatar
Alexander Larsson committed
70

71
freedesktop-sdk.tar.gz freedesktop-sdk-rpmdb.tar.gz: $(NOARCH)/freedesktop-sdk-0.1-1.sdk.noarch.rpm
72
	./setup.sh $(IMAGES)/freedesktop-contents-sdk-$(ARCH).tar.gz
73
74
75
76
77
	./build.sh smart install -y  $(NOARCH)/freedesktop-sdk-0.1-1.sdk.noarch.rpm
	rm -rf freedesktop-sdk.tar.gz freedesktop-sdk-rpmdb.tar.gz
	tar --transform 's,^root/usr,files,S' -czf freedesktop-sdk.tar.gz root/usr --owner=root
	tar --transform 's,^var,files,S' -czf freedesktop-sdk-rpmdb.tar.gz var/lib/rpm --owner=root

78
freedesktop-platform-base: $(NOARCH)/freedesktop-platform-base-0.1-1.sdk.noarch.rpm
79

80
$(NOARCH)/freedesktop-platform-base-0.1-1.sdk.noarch.rpm: $(SPECS)/freedesktop-platform-base.spec setup.sh build.sh $(IMAGES)/freedesktop-contents-platform-$(ARCH).tar.gz $(IMAGES)/freedesktop-contents-sdk-$(ARCH).tar.gz
81
82
83
	-echo building freedesktop-platform-base.spec
	rm -rf packages/freedesktop-platform
	mkdir -p packages/freedesktop-platform
84
85
	tar -C packages/freedesktop-platform -xzf $(IMAGES)/freedesktop-contents-platform-$(ARCH).tar.gz
	./setup.sh $(IMAGES)/freedesktop-contents-sdk-$(ARCH).tar.gz
86
	./build.sh rpmbuild -ba $(SPECS)/freedesktop-platform-base.spec
87

88
freedesktop-sdk-base: $(NOARCH)/freedesktop-sdk-base-0.1-1.sdk.noarch.rpm
89

90
freedesktop-platform-packages: $(NOARCH)/freedesktop-platform-0.1-1.sdk.noarch.rpm $(NOARCH)/freedesktop-platform-base-0.1-1.sdk.noarch.rpm setup.sh build.sh
91
	./setup.sh $(IMAGES)/freedesktop-contents-sdk-$(ARCH).tar.gz
92
93
94
	rm -f freedesktop-platform-packages
	./build.sh ./list_packages.sh freedesktop-platform > freedesktop-platform-packages

95
freedesktop-platform.tar.gz freedesktop-platform-rpmdb.tar.gz: freedesktop-platform-packages $(NOARCH)/freedesktop-platform-0.1-1.sdk.noarch.rpm setup.sh build.sh $(IMAGES)/freedesktop-contents-platform-$(ARCH).tar.gz
96
	-echo building freedesktop-platform
97
	./setup_root.sh $(IMAGES)/freedesktop-contents-platform-$(ARCH).tar.gz
98
99
100
101
	./build.sh rpm -Uvh `cat freedesktop-platform-packages`
	tar --transform 's,^root/usr,files,S' -czf freedesktop-platform.tar.gz root/usr --owner=root
	tar --transform 's,^var,files,S' -czf freedesktop-platform-rpmdb.tar.gz var/lib/rpm --owner=root

102
gnome-platform-packages: $(NOARCH)/gnome-platform-0.1-1.sdk.noarch.rpm $(NOARCH)/freedesktop-platform-base-0.1-1.sdk.noarch.rpm setup.sh build.sh
103
	./setup.sh $(IMAGES)/freedesktop-contents-sdk-$(ARCH).tar.gz
104
	rm -f gnome-platform-packages
105
	./build.sh ./list_packages.sh gnome-platform > gnome-platform-packages
106

107
gnome-platform.tar.gz gnome-platform-rpmdb.tar.gz: gnome-platform-packages $(NOARCH)/gnome-platform-0.1-1.sdk.noarch.rpm setup.sh build.sh $(IMAGES)/freedesktop-contents-platform-$(ARCH).tar.gz
108
	-echo building gnome-platform
109
	./setup_root.sh $(IMAGES)/freedesktop-contents-platform-$(ARCH).tar.gz
110
	./build.sh rpm -Uvh `cat gnome-platform-packages`
111
	tar --transform 's,^root/usr,files,S' -czf gnome-platform.tar.gz root/usr --owner=root
Alexander Larsson's avatar
Alexander Larsson committed
112
	tar --transform 's,^var,files,S' -czf gnome-platform-rpmdb.tar.gz var/lib/rpm --owner=root
113
114
115
116

repository:
	ostree  init --mode=archive-z2 --repo=repository

117
118
119
120
121
122
commit-freedesktop-platform: repository freedesktop-platform.tar.gz  freedesktop-platform-rpmdb.tar.gz
	./commit.sh repository freedesktop-platform.tar.gz freedesktop-platform-rpmdb.tar.gz metadata.freedesktop-platform org.freedesktop.Platform $(ARCH) $(FREEDESKTOP_VERSION)

commit-freedesktop-sdk: repository freedesktop-sdk.tar.gz freedesktop-sdk-rpmdb.tar.gz
	./commit.sh repository freedesktop-sdk.tar.gz freedesktop-sdk-rpmdb.tar.gz metadata.freedesktop-sdk org.freedesktop.Sdk $(ARCH) $(FREEDESKTOP_VERSION)

Alexander Larsson's avatar
Alexander Larsson committed
123
commit-platform: repository gnome-platform.tar.gz  gnome-platform-rpmdb.tar.gz
124
	./commit.sh repository gnome-platform.tar.gz gnome-platform-rpmdb.tar.gz metadata.platform org.gnome.Platform $(ARCH) $(GNOME_VERSION)
125

Alexander Larsson's avatar
Alexander Larsson committed
126
commit-sdk: repository gnome-sdk.tar.gz gnome-sdk-rpmdb.tar.gz
127
	./commit.sh repository gnome-sdk.tar.gz gnome-sdk-rpmdb.tar.gz metadata.sdk org.gnome.Sdk $(ARCH) $(GNOME_VERSION)
128

129
commit-gnome: commit-sdk commit-platform
Alexander Larsson's avatar
Alexander Larsson committed
130
	echo done
131

132
133
134
135
136
137
commit-freedesktop: commit-freedesktop-sdk commit-freedesktop-platform
	echo done

commit: commit-gnome commit-freedesktop
	echo done

138
139
140
141
release/repo:
	ostree  init --mode=archive-z2 --repo=release/repo

release-commit-freedesktop-platform: release/repo freedesktop-platform.tar.gz  freedesktop-platform-rpmdb.tar.gz
142
143
	./commit.sh release/repo freedesktop-platform.tar.gz freedesktop-platform-rpmdb.tar.gz metadata.freedesktop-platform org.freedesktop.Platform $(ARCH) $(FREEDESKTOP_VERSION)

144
release-commit-freedesktop-sdk: release/repo freedesktop-sdk.tar.gz freedesktop-sdk-rpmdb.tar.gz
145
146
	./commit.sh release/repo freedesktop-sdk.tar.gz freedesktop-sdk-rpmdb.tar.gz metadata.freedesktop-sdk org.freedesktop.Sdk $(ARCH) $(FREEDESKTOP_VERSION)

Alexander Larsson's avatar
Alexander Larsson committed
147
release-commit-platform: release/repo gnome-platform.tar.gz  gnome-platform-rpmdb.tar.gz
148
	./commit.sh release/repo gnome-platform.tar.gz gnome-platform-rpmdb.tar.gz metadata.platform org.gnome.Platform $(ARCH) $(GNOME_VERSION)
Alexander Larsson's avatar
Alexander Larsson committed
149
150

release-commit-sdk: release/repo gnome-sdk.tar.gz gnome-sdk-rpmdb.tar.gz
151
152
153
154
	./commit.sh release/repo gnome-sdk.tar.gz gnome-sdk-rpmdb.tar.gz metadata.sdk org.gnome.Sdk $(ARCH) $(GNOME_VERSION)

release-commit-gnome: release-commit-sdk release-commit-platform
	echo done
155

156
157
release-commit-freedesktop: release-commit-freedesktop-sdk release-commit-freedesktop-platform
	echo done
Alexander Larsson's avatar
Alexander Larsson committed
158

159
release-commit: release-commit-gnome release-commit-freedesktop
160
	echo done
161

Alexander Larsson's avatar
Alexander Larsson committed
162
-include rpm-dependencies.P