diff options
author | Kai Sommerfeld <kai.sommerfeld@gmx.com> | 2021-09-24 19:20:04 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-09-24 19:20:04 +0200 |
commit | 6db5bf6cd20169e720f12170a0e1132fe7c7b1b7 (patch) | |
tree | cc4f0116c53be5d750efbdcd0d109cdc92dfa486 /tools | |
parent | 186c54e2e632fdafb5ab66488d12bb8644b09697 (diff) | |
parent | 14b5c4844e15a5cb231e19c1f8d8d1fd05669f04 (diff) |
Merge pull request #19937 from matthuisman/add_lzma_19
[Backport][Python] Add Python lzma module
Diffstat (limited to 'tools')
-rw-r--r-- | tools/depends/target/Makefile | 5 | ||||
-rw-r--r-- | tools/depends/target/python3/modules.setup | 1 | ||||
-rw-r--r-- | tools/depends/target/xz/Makefile | 37 |
3 files changed, 41 insertions, 2 deletions
diff --git a/tools/depends/target/Makefile b/tools/depends/target/Makefile index 5b8faf8872..85d2c26b53 100644 --- a/tools/depends/target/Makefile +++ b/tools/depends/target/Makefile @@ -15,7 +15,7 @@ DEPENDS = \ taglib libusb libnfs \ pythonmodule-pil pythonmodule-pycryptodome pythonmodule-setuptools \ libxslt ffmpeg crossguid libudfread \ - libdvdread libdvdnav libdvdcss p8-platform flatbuffers dav1d + libdvdread libdvdnav libdvdcss p8-platform flatbuffers dav1d xz ifeq ($(ENABLE_GPLV3),yes) DEPENDS+=samba-gplv3 libcdio-gplv3 @@ -87,12 +87,13 @@ endif all: .installed-$(PLATFORM) gettext: $(ICONV) +xz: gettext libgcrypt: libgpg-error fontconfig: freetype2 expat $(ICONV) $(LIBUUID) curl: openssl nghttp2 libass: fontconfig fribidi libpng freetype2 expat $(ICONV) libmicrohttpd: gnutls libgcrypt libgpg-error -python3: expat gettext libxml2 sqlite3 openssl libffi bzip2 +python3: expat gettext libxml2 sqlite3 openssl libffi bzip2 xz libcdio: $(ICONV) libcdio-gplv3: $(ICONV) libplist: $(ZLIB) diff --git a/tools/depends/target/python3/modules.setup b/tools/depends/target/python3/modules.setup index a7db7a2eb7..518691a9ec 100644 --- a/tools/depends/target/python3/modules.setup +++ b/tools/depends/target/python3/modules.setup @@ -380,6 +380,7 @@ _ctypes _ctypes/callbacks.c _ctypes/callproc.c _ctypes/cfield.c _ctypes/_ctyp _queue _queuemodule.c _bz2 _bz2module.c -I$(prefix)/include -L$(prefix)/lib -lbz2 +_lzma _lzmamodule.c -I$(prefix)/include -L$(prefix)/lib -llzma # Uncommenting the following line tells makesetup that all following modules # are not built (see above for more detail). diff --git a/tools/depends/target/xz/Makefile b/tools/depends/target/xz/Makefile new file mode 100644 index 0000000000..8e4fdb1fe9 --- /dev/null +++ b/tools/depends/target/xz/Makefile @@ -0,0 +1,37 @@ +include ../../Makefile.include +DEPS= ../../Makefile.include Makefile + +# lib name, version +LIBNAME=xz +VERSION=5.2.5 +SOURCE=$(LIBNAME)-$(VERSION) +ARCHIVE=$(SOURCE).tar.gz + +# configuration settings +CONFIGURE=./configure --prefix=$(PREFIX) --disable-shared --disable-assembler --disable-lzmainfo --disable-lzma-links --disable-scripts --disable-doc + +LIBDYLIB=$(PLATFORM)/src/liblzma/liblzma.a + +all: .installed-$(PLATFORM) + +$(TARBALLS_LOCATION)/$(ARCHIVE): + cd $(TARBALLS_LOCATION); $(RETRIEVE_TOOL) $(RETRIEVE_TOOL_FLAGS) $(BASE_URL)/$(ARCHIVE) + +$(PLATFORM): $(TARBALLS_LOCATION)/$(ARCHIVE) $(DEPS) + rm -rf $(PLATFORM)/*; mkdir -p $(PLATFORM) + cd $(PLATFORM); $(ARCHIVE_TOOL) $(ARCHIVE_TOOL_FLAGS) $(TARBALLS_LOCATION)/$(ARCHIVE) + cd $(PLATFORM); $(CONFIGURE) + +$(LIBDYLIB): $(PLATFORM) + $(MAKE) -C $(PLATFORM) + +.installed-$(PLATFORM): $(LIBDYLIB) + $(MAKE) -C $(PLATFORM) install + touch $@ + +clean: + $(MAKE) -C $(PLATFORM) clean + rm -f .installed-$(PLATFORM) + +distclean:: + rm -rf $(PLATFORM) .installed-$(PLATFORM) |