Skip to content

Build under alpine with pecl install & docker-php-ext-enable? #30

@roynasser

Description

@roynasser

Hi, has anyone had success building and enabling jsonc with PHP5.6 images for alpine?

This is what I get, which from other issues would seem to point to permission / running under root / bad prefix / etc which shouldnt be an issue using the docker-php-ext pattern (and considering I'm building other extensions in the same manner)... I wonder if this may be something from alpine which isnt compatible... Unfortunately I need to up the json version in order to get elasticsearch working correctly...

Thanks!

downloading jsonc-1.3.9.tgz ...
Starting to download jsonc-1.3.9.tgz (75,383 bytes)
.................done: 75,383 bytes
30 source files, building
running: phpize
Configuring for:
PHP Api Version: 20131106
Zend Module Api No: 20131226
Zend Extension Api No: 220131226
building in /tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9
running: /tmp/pear/temp/jsonc/configure --with-php-config=/usr/local/bin/php-config
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for a sed that does not truncate output... /bin/sed
checking for cc... cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking how to run the C preprocessor... cc -E
checking for icc... no
checking for suncc... no
checking whether cc understands -c and -o together... yes
checking for system library directory... lib
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for PHP prefix... /usr/local
checking for PHP includes... -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib
checking for PHP extension directory... /usr/local/lib/php/extensions/no-debug-non-zts-20131226
checking for PHP installed headers prefix... /usr/local/include/php
checking if debug is enabled... no
checking if zts is enabled... no
checking for re2c... no
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
checking for gawk... no
checking for nawk... no
checking for awk... awk
checking if awk is broken... no
checking whether to enable JavaScript Object Serialization support... yes, shared
checking whether to rename module file to jsonc... no
checking libjson... no
checking whether to enable RDRAND Hardware RNG Hash Seed generation on supported x86/x64 platforms... yes
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define EXTENSIONS... yes
checking for ANSI C header files... (cached) yes
checking for working sscanf... no, not working
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking for strings.h... (cached) yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking for unistd.h... (cached) yes
checking sys/param.h usability... yes
checking sys/param.h presence... yes
checking for sys/param.h... yes
checking stdarg.h usability... yes
checking stdarg.h presence... yes
checking for stdarg.h... yes
checking for inttypes.h... (cached) yes
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking endian.h usability... yes
checking endian.h presence... yes
checking for endian.h... yes
checking for strcasecmp... yes
checking for strdup... yes
checking for strndup... yes
checking for strerror... yes
checking for snprintf... yes
checking for vsnprintf... yes
checking for vasprintf... yes
checking for open... yes
checking for vsyslog... yes
checking for strncasecmp... yes
checking for setlocale... yes
checking JSON extension name:... json
checking for ld used by cc... /usr/x86_64-alpine-linux-musl/bin/ld
checking if the linker (/usr/x86_64-alpine-linux-musl/bin/ld) is GNU ld... yes
checking for /usr/x86_64-alpine-linux-musl/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/bin/nm -B
checking whether ln -s works... yes
checking how to recognize dependent libraries... pass_all
/tmp/pear/temp/jsonc/configure: ./configure.lineno: line 1: /usr/bin/file: not found
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking the maximum length of command line arguments... 98304
checking command to parse /usr/bin/nm -B output from cc object... ok
checking for objdir... .libs
checking for ar... ar
checking for ranlib... ranlib
checking for strip... strip
checking if cc supports -fno-rtti -fno-exceptions... no
checking for cc option to produce PIC... -fPIC
checking if cc PIC flag -fPIC works... yes
checking if cc static flag -static works... yes
checking if cc supports -c -o file.o... yes
checking whether the cc linker (/usr/x86_64-alpine-linux-musl/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no

creating libtool
appending configuration tag "CXX" to libtool
configure: creating ./config.status
config.status: creating config.h
running: make
/bin/sh /tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9/libtool --mode=compile cc -I. -I/tmp/pear/temp/jsonc -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9/include -I/tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9/main -I/tmp/pear/temp/jsonc -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /tmp/pear/temp/jsonc/json.c -o json.lo
mkdir .libs
cc -I. -I/tmp/pear/temp/jsonc -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9/include -I/tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9/main -I/tmp/pear/temp/jsonc -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /tmp/pear/temp/jsonc/json.c -fPIC -DPIC -o .libs/json.o
/bin/sh /tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9/libtool --mode=compile cc -I. -I/tmp/pear/temp/jsonc -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9/include -I/tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9/main -I/tmp/pear/temp/jsonc -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /tmp/pear/temp/jsonc/json-c/arraylist.c -o json-c/arraylist.lo
/tmp/pear/temp/pear-build-defaultuserOpBGbp/jsonc-1.3.9/libtool: line 7085: can't create json-c/arraylist.loT: nonexistent directory
mkdir json-c/.libs
mkdir: cannot create directory ‘json-c/.libs’: No such file or directory
make: *** [Makefile:183: json-c/arraylist.lo] Error 1
ERROR: `make' failed

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions