Skip to content

Commit 0887c2f

Browse files
committed
Update glib to 2.59.3
Requires meson -> python3
1 parent 7cdd53b commit 0887c2f

File tree

4 files changed

+18
-14
lines changed

4 files changed

+18
-14
lines changed

.github/workflows/build.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,19 +23,22 @@ jobs:
2323
apt-get update && apt-get install -y -q
2424
autoconf
2525
bison
26+
build-essential
2627
cmake
2728
flex
2829
gettext
2930
git-core
3031
intltool
3132
libglib2.0-dev
3233
libtool
34+
meson
3335
mingw-w64
36+
ninja
3437
nsis
3538
pkg-config
3639
protobuf-compiler
37-
python
38-
python-dev
40+
python3
41+
python3-setuptools
3942
stow
4043
sudo
4144
texinfo

downloader/downloader.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import os
44
import sys
55
import urllib
6+
import urllib.request
67

78
DOWNLOAD_URL = 'https://storage.googleapis.com/clementine-data.appspot.com/Build%20dependencies/'
89

@@ -18,7 +19,7 @@
1819
('gettext-0.20.2.tar.xz', '0cf5f68338d5d941bbf9ac93b847310f'),
1920
('glew-1.5.5.tar.bz2', '25afa3ff4cff7b67add612e148a54240'),
2021
('glew-1.5.5-win32.zip', '48c8c982644ba11dfe94aaf756217eec'),
21-
('glib-2.58.3.tar.xz', '8058c7bde846dcffe5fa453eca366d73'),
22+
('glib-2.59.3.tar.xz', '9a06eb1a7143a17050b0b1abef2208e1'),
2223
('glib-networking-2.54.1.tar.xz', '99867463f182c2767bce0c74bc9cc981'),
2324
('gmp-6.2.0.tar.xz', 'a325e3f09e6d91e62101e59f9bda3ec1'),
2425
('gnutls-3.6.13.tar.xz', 'bb1fe696a11543433785b4fc70ca225f'),
@@ -74,7 +75,7 @@ def Md5File(path):
7475

7576
file_hash = hashlib.md5()
7677
try:
77-
with open(path) as fh:
78+
with open(path, 'rb') as fh:
7879
while True:
7980
chunk = fh.read(4096)
8081
if len(chunk) == 0:
@@ -103,8 +104,8 @@ def DownloadFiles(flags):
103104
if actual_md5_checksum != md5_checksum:
104105
url = DOWNLOAD_URL + name
105106

106-
print 'Downloading %s...' % name
107-
urllib.urlretrieve(url, path)
107+
print('Downloading %s...' % name)
108+
urllib.request.urlretrieve(url, path)
108109
actual_md5_checksum = Md5File(path)
109110

110111
# If the checksum still didn't match the download must have failed.
@@ -113,7 +114,7 @@ def DownloadFiles(flags):
113114
'Download failed - checksums do not match (got %s, expected %s)' %
114115
(actual_md5_checksum, md5_checksum))
115116

116-
print 'All files are up-to-date'
117+
print('All files are up-to-date')
117118

118119

119120
def Main(argv):

makefile.common

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ flac=flac-1.3.3
1010
gcrypt=libgcrypt-1.8.5
1111
gettext=gettext-0.20.2
1212
glew=glew-1.5.5
13-
glib=glib-2.58.3
13+
glib=glib-2.59.3
1414
glibnetworking=glib-networking-2.54.1
1515
gmp=gmp-6.2.0
1616
gnutls=gnutls-3.6.13
@@ -137,7 +137,7 @@ all:
137137
$(MAKE) clementine-deps
138138

139139
clean:
140-
realstow=`python -c "import os.path; print os.path.realpath('$(stow)')"`; \
140+
realstow=`python3 -c "import os.path; print os.path.realpath('$(stow)')"`; \
141141
for path in $(stow)/*; do \
142142
directory=`basename $$path`; \
143143
stow -d $$realstow -D $$directory; \
@@ -148,7 +148,7 @@ clean:
148148
-rm .done-*
149149

150150
all-downloads:
151-
python $(src)/downloader/downloader.py --output "$(downloads)"
151+
python3 $(src)/downloader/downloader.py --output "$(downloads)"
152152

153153
boost: .done-boost
154154
cdio: .done-cdio

windows/Makefile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -271,10 +271,10 @@ clementine-deps: clementine-build-deps clementine-gst-plugins openssl glibnetwor
271271

272272
.done-glib: .done-zlib .done-gettext .done-ffi .done-pcre
273273
$(call extractpkg,$(glibtgz))
274-
cd $(glib) && ./autogen.sh
275-
cd $(glib) && $(configure) CFLAGS="$(cflags) -Wno-format-security -Wno-format-overflow -Wno-format-nonliteral"
276-
cd $(glib) && $(make)
277-
$(call installpkg,$(glib))
274+
cd $(glib) && meson --cross-file ../cross-file.txt _build
275+
cd $(glib) && ninja -C _build
276+
cd $(glib) && DESTDIR=$(stow)/$(glib) ninja -C _build install
277+
touch $@
278278

279279
.done-gmp:
280280
rm -f $(prefix)/share/info/dir

0 commit comments

Comments
 (0)