Php: install xsl on php:7.1-fpm-alpine

Created on 4 Apr 2018  路  1Comment  路  Source: docker-library/php

Hello, i need xsl ext on php, and make this dockerfile

FROM php:7.1-fpm-alpine

RUN apk upgrade --update && apk add --no-cache \
    freetype libpng libjpeg-turbo \
    && apk add --virtual build-deps freetype-dev libpng-dev libjpeg-turbo-dev libxslt-dev libxml2-dev \
    && docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ \
    && export NPROC=$(grep -c ^processor /proc/cpuinfo 2>/dev/null || 1) \
    && docker-php-ext-install -j${NPROC} mysqli opcache xsl gd \
    && apk del build-deps

after that i have error
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20160303/xsl.so' - Error loading shared library libexslt.so.0: No such file or directory (needed by /usr/local/lib/php/extensions/no-debug-non-zts-20160303/xsl.so) in Unknown on line 0

Can u help me?)

Most helpful comment

You need to add libxslt to your non-build-deps list so that libexslt.so.0 will still be there after building the extension.

>All comments

You need to add libxslt to your non-build-deps list so that libexslt.so.0 will still be there after building the extension.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

skyzyx picture skyzyx  路  3Comments

2Kable picture 2Kable  路  3Comments

cmath10 picture cmath10  路  3Comments

cordoval picture cordoval  路  3Comments

ktrzos picture ktrzos  路  3Comments