summaryrefslogblamecommitdiff
path: root/system/libxml2/APKBUILD
blob: 9c294b6e7759f6826661625c323513f08f33a27f (plain) (tree)
1
2
3
4
5
6
7
8
9
                                                     
                                                 
               


                  
                             

                             
                                                 
             
          
                              

                                                                

                                                     

                                                                                 

                                 







                     


                      
 

                                            

                       


         
                      






                                           
                                              


            



                                    
           








                                                       
                                          
                                               



                                                           

                                                                                                                                                                                 
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=libxml2
pkgver=2.9.13_pre1
pkgdate=20220112
pkgrel=0
pkgdesc="XML parsing library"
url="http://www.xmlsoft.org/"
arch="all"
options="!strip"  # Impossible to run on Python 3
license="MIT"
depends=""
depends_dev="zlib-dev icu-dev"
checkdepends="perl libarchive"
makedepends="$depends_dev python3-dev autoconf automake libtool"
subpackages="$pkgname-doc $pkgname-dev py-libxml2:py"
provides="$pkgname-utils=$pkgver-r$pkgrel"
#source="ftp://ftp.xmlsoft.org/${pkgname}/${pkgname}-${pkgver}.tar.gz"
source="https://distfiles.adelielinux.org/source/$pkgname-$pkgver-$pkgdate.tar.gz
	python-segfault-fix.patch
	"

# secfixes:
#   2.9.4-r1:
#     - CVE-2016-5131
#   2.9.4-r2:
#     - CVE-2016-9318
#   2.9.4-r4:
#     - CVE-2017-5969
#   2.9.10-r1:
#     - CVE-2019-20388
#     - CVE-2020-7595

builddir="$srcdir/$pkgname-$pkgver-$pkgdate"

prepare() {
	default_prepare
}

build() {
	./autogen.sh \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--with-icu \
		--with-python=/usr/bin/python3
	make
}

check() {
	make -ik check # FIXME: #465
}

package() {
	make -j1 DESTDIR="$pkgdir" install
}

dev() {
	default_dev
	mv "$pkgdir"/usr/lib/*.sh "$subpkgdir"/usr/lib/
}

py() {
	pkgdesc="$pkgname Python bindings"
	provides="py3-libxml2=$pkgver-r$pkgrel"
	install -d "$subpkgdir"/usr/lib
	mv "$pkgdir"/usr/lib/python3* "$subpkgdir"/usr/lib/
}

sha512sums="fed9e35478f169411700e5216ebf9735afbde5bcc2a6f9ad81959d11907d28d9ed4281613af31ef410aeef6acbd6e62dd168268f75454a9942261a86db3933ff  libxml2-2.9.13_pre1-20220112.tar.gz
384b3d2031cd8f77528190bbb7652faa9ccb22bc604bcf4927e59046d38830dac38010828fe1568b6514976f725981a6d3ac1aa595d31477a36db2afe491452c  python-segfault-fix.patch"