Open C0nw0nk opened 3 years ago
./configure: 33: ../incubator-pagespeed-ngx//config: [[: not found
First thing that comes to mind is that [[ is a bash command, are you running in sh or another shell?
The PSOL folder must be a sub-folder where you have pagespeed. Example. you download the incubator-pagespeed-ngx-1.14.36.1-beta.tar.gz and untar it, then you have a folder incubator-pagespeed-ngx-1.14.36.1-beta/. Next, you go to these folder (cd /path/to/the/folder/incubator-pagespeed-ngx-1.14.36.1-beta/ ) then download the psol library and untar it. Now you have some like incubator-pagespeed-ngx-1.14.36.1-beta/psol/lib/Release/linux/x64/pagespeed_automatic.a
Or maybe you need these steps: https://groups.google.com/g/ngx-pagespeed-discuss/c/PSrbZrjKpKI/m/TtE59WSfAwAJ
I have same issue with nginx 1.20 with fedora server 34 ngx_pagespeed-release-1.13.35.2. Psol directory is exist, but still failing to detect. Seems like config file issue Attempt build RPM with mockbuild
The question why you need ask interactive question in middle of config file ?
adding module in /builddir/build/BUILD/nginx-1.20.2/ngx_pagespeed-release-1.13.35.2
You have set --with-debug for building nginx, but precompiled Debug binaries for
PSOL, which ngx_pagespeed depends on, aren't available. If you're trying to
debug PSOL you need to build it from source. If you just want to run nginx with
debug-level logging you can use the Release binaries.
**Use the available Release binaries?**
mod_pagespeed_dir=/builddir/build/BUILD/nginx-1.20.2/ngx_pagespeed-release-1.13.35.2/psol/include
build_from_source=false
checking for psol ... not found
./configure: error: module ngx_pagespeed requires the pagespeed optimization library.
Look in /builddir/build/BUILD/nginx-1.20.2/objs/autoconf.err for more details.
error: Bad exit status from /var/tmp/rpm-tmp.HJYM2B (%build)
[volga629@canldev01-fedora32 ngx_pagespeed-release-1.13.35.2]$ ls
config config.make cpp_feature LICENSE psol PSOL_BINARY_URL README.md scripts src test
[volga629@canldev01-fedora32 ngx_pagespeed-release-1.13.35.2]$ ls -la psol/
total 20
drwxrwxr-x 4 volga629 volga629 4096 Jan 25 2018 .
drwxrwxr-x 6 volga629 volga629 4096 Dec 12 20:12 ..
drwxr-xr-x 10 volga629 volga629 4096 Jan 25 2018 include
-rw-rw-r-- 1 volga629 volga629 136 Jan 25 2018 include_history.txt
drwxrwxr-x 3 volga629 volga629 4096 Jan 25 2018 lib
[volga629@canldev01-fedora32 ngx_pagespeed-release-1.13.35.2]$
No need it code
echo "
You have set --with-debug for building nginx, but precompiled Debug binaries for
PSOL, which ngx_pagespeed depends on, aren't available. If you're trying to
debug PSOL you need to build it from source. If you just want to run nginx with
debug-level logging you can use the Release binaries."
echo -n "
Use the available Release binaries?"
read -p " [Y/n] " yn
if [[ "$yn" == N* || "$yn" == n* ]]; then
echo "Cancelled."
exit 1
fi
But under lib there are others folders (/lib/Release/linux/x64/pagespeed_automatic.a) Maybe the download from https://dl.google.com/dl/page-speed/psol/ fails. I don´t know if these repository is working For never version you can find it at https://dist.apache.org/repos/dist/release/incubator/pagespeed/1.14.36.1/x64/ Maybe you can use the nginx module 1.13.35.2. with this latest psol
But why need download if full library folder exist ?
<mock-chroot> sh-5.1# cd modsecurity-nginx-v1.0.1/
<mock-chroot> sh-5.1# cd ../ngx_pagespeed-release-1.13.35.2
<mock-chroot> sh-5.1# find . -name pagespeed_automatic.a
./psol/lib/Release/linux/x64/pagespeed_automatic.a
<mock-chroot> sh-5.1#
I´m asking because in the script install the psol is downloaded from a google site and some times this download fail, since the module don´t be a google proyect. So maybe the folders are in place, but not the file.. I never used to install from scripts, do the manual way. Download the ngx_pagespeed, uncompress, go to the directory, download the psol and uncompress it, then delete the downloaded psol compressed file, and create a tar.gz, donwload the nginx sources, put the create tar.gz ib sources and modify the nginx.spec and do rpmbuild. When asked, put Y to use the psol library in pakage and get the rpm package
I think we might need to update https://www.modpagespeed.com/doc/build_ngx_pagespeed_from_source to point to a download page under Apache rather than https://dl.google.com/dl/page-speed/psol/${NPS_RELEASE_NUMBER}.tar.gz -- Otto what was your thinking about this?
@jmarantz that makes sense, I'll look into that.
With some fiddling this produces an nginx binary for me:
#!/bin/bash
set -x
NPS_VERSION=1.14.33.1-RC1
NPS_RELEASE_NUMBER=1.14.36.1
PS_NGX_EXTRA_FLAGS=--with-cc-opt=-Wno-error
wget -O- https://github.com/apache/incubator-pagespeed-ngx/archive/refs/tags/v${NPS_VERSION}.tar.gz | tar -xz
nps_dir=$(realpath $(find . -name "*pagespeed-ngx-${NPS_VERSION}" -type d))
cd "$nps_dir"
psol_url=https://dl.google.com/dl/page-speed/psol/${NPS_RELEASE_NUMBER}.tar.gz
[ -e scripts/format_binary_url.sh ] && psol_url=$(scripts/format_binary_url.sh PSOL_BINARY_URL)
wget -O- ${psol_url} | tar -xz # extracts to psol/
NGINX_VERSION=1.18.0
wget -O- http://nginx.org/download/nginx-${NGINX_VERSION}.tar.gz | tar -xz
cd nginx-${NGINX_VERSION}/
./configure --add-module=$nps_dir ${PS_NGX_EXTRA_FLAGS}
make -j 80
Notes:
With some fiddling this produces an nginx binary for me:
#!/bin/bash set -x NPS_VERSION=1.14.33.1-RC1 NPS_RELEASE_NUMBER=1.14.36.1 PS_NGX_EXTRA_FLAGS=--with-cc-opt=-Wno-error wget -O- https://github.com/apache/incubator-pagespeed-ngx/archive/refs/tags/v${NPS_VERSION}.tar.gz | tar -xz nps_dir=$(realpath $(find . -name "*pagespeed-ngx-${NPS_VERSION}" -type d)) cd "$nps_dir" psol_url=https://dl.google.com/dl/page-speed/psol/${NPS_RELEASE_NUMBER}.tar.gz [ -e scripts/format_binary_url.sh ] && psol_url=$(scripts/format_binary_url.sh PSOL_BINARY_URL) wget -O- ${psol_url} | tar -xz # extracts to psol/ NGINX_VERSION=1.18.0 wget -O- http://nginx.org/download/nginx-${NGINX_VERSION}.tar.gz | tar -xz cd nginx-${NGINX_VERSION}/ ./configure --add-module=$nps_dir ${PS_NGX_EXTRA_FLAGS} make -j 80
Notes:
- During the release process, I didn't go ahead and release ngx_pagespeed along with mod_pagespeed. This is because that would need ngx_pagespeed to go through some more compliance checking to ensure it is on par with ASF standards.
- I did however go as far as tagging a release candidate. Unfortunately I made a typo (1.14.33.1-RC1 ought to have been 1.14.36.1-RC1). This is what we use above. I think it would be OK for us to update the documentation with a script similar to what I am posting here, as long as we add a disclaimer/warning about this being a WIP from an ASF policy PoV.
According to this, I still fail to build on Alpine 3.15 (alpine:3.15).
I already install [libuuid] and [util-linux-dev] (contains uuid/uuid.h and libuuid.so) and other depends.
The compilation parameters use the parameters of the nginx official alpine container.
./configure --prefix=/etc/nginx \
--sbin-path=/usr/sbin/nginx \
--modules-path=/usr/lib/nginx/modules \
--conf-path=/etc/nginx/nginx.conf \
--error-log-path=/var/log/nginx/error.log \
--http-log-path=/var/log/nginx/access.log \
--pid-path=/var/run/nginx.pid \
--lock-path=/var/run/nginx.lock \
--http-client-body-temp-path=/var/cache/nginx/client_temp \
--http-proxy-temp-path=/var/cache/nginx/proxy_temp \
--http-fastcgi-temp-path=/var/cache/nginx/fastcgi_temp \
--http-uwsgi-temp-path=/var/cache/nginx/uwsgi_temp \
--http-scgi-temp-path=/var/cache/nginx/scgi_temp \
--with-perl_modules_path=/usr/lib/perl5/vendor_perl \
--user=nginx \
--group=nginx \
--with-compat \
--with-file-aio \
--with-threads \
--with-http_addition_module \
--with-http_auth_request_module \
--with-http_dav_module \
--with-http_flv_module \
--with-http_gunzip_module \
--with-http_gzip_static_module \
--with-http_mp4_module \
--with-http_random_index_module \
--with-http_realip_module \
--with-http_secure_link_module \
--with-http_slice_module \
--with-http_ssl_module \
--with-http_stub_status_module \
--with-http_sub_module \
--with-http_v2_module --with-mail \
--with-mail_ssl_module --with-stream \
--with-stream_realip_module \
--with-stream_ssl_module \
--with-stream_ssl_preread_module \
--add-dynamic-module=/usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1 \
--with-cc-opt='-Os -fomit-frame-pointer -g' \
--with-ld-opt=-Wl,--as-needed,-O1,--sort-common
The lib already exists.
# find /usr/src/ -name pagespeed_automatic.a
/usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a
Error log /usr/src/nginx-1.20.2/objs/autoconf.err
head -n 500 /usr/src/nginx-1.20.2/objs/autoconf.err
----------------------------------------
checking for C compiler
----------------------------------------
checking for gcc -pipe switch
----------------------------------------
checking for --with-ld-opt="-Wl,--as-needed,-O1,--sort-common"
----------------------------------------
checking for -Wl,-E switch
----------------------------------------
checking for gcc builtin atomic operations
----------------------------------------
checking for C99 variadic macros
----------------------------------------
checking for gcc variadic macros
----------------------------------------
checking for gcc builtin 64 bit byteswap
----------------------------------------
checking for unistd.h
----------------------------------------
checking for inttypes.h
----------------------------------------
checking for limits.h
----------------------------------------
checking for sys/filio.h
objs/autotest.c:3:10: fatal error: sys/filio.h: No such file or directory
3 | #include <sys/filio.h>
| ^~~~~~~~~~~~~
compilation terminated.
----------
#include <sys/filio.h>
int main(void) {
return 0;
}
----------
cc -o objs/autotest objs/autotest.c
----------
----------------------------------------
checking for sys/param.h
----------------------------------------
checking for sys/mount.h
----------------------------------------
checking for sys/statvfs.h
----------------------------------------
checking for crypt.h
----------------------------------------
checking for epoll
----------------------------------------
checking for EPOLLRDHUP
----------------------------------------
checking for EPOLLEXCLUSIVE
----------------------------------------
checking for eventfd()
----------------------------------------
checking for O_PATH
----------------------------------------
checking for sendfile()
----------------------------------------
checking for sendfile64()
----------------------------------------
checking for sys/prctl.h
----------------------------------------
checking for prctl(PR_SET_DUMPABLE)
----------------------------------------
checking for prctl(PR_SET_KEEPCAPS)
----------------------------------------
checking for capabilities
----------------------------------------
checking for crypt_r()
----------------------------------------
checking for sys/vfs.h
----------------------------------------
checking for poll()
----------------------------------------
checking for /dev/poll
objs/autotest.c:4:10: fatal error: sys/devpoll.h: No such file or directory
4 | #include <sys/devpoll.h>
| ^~~~~~~~~~~~~~~
compilation terminated.
----------
#include <sys/types.h>
#include <unistd.h>
#include <sys/devpoll.h>
int main(void) {
int n, dp; struct dvpoll dvp;
dp = 0;
dvp.dp_fds = NULL;
dvp.dp_nfds = 0;
dvp.dp_timeout = 0;
n = ioctl(dp, DP_POLL, &dvp);
if (n == -1) return 1;
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for kqueue
objs/autotest.c:4:10: fatal error: sys/event.h: No such file or directory
4 | #include <sys/event.h>
| ^~~~~~~~~~~~~
compilation terminated.
----------
#include <sys/types.h>
#include <unistd.h>
#include <sys/event.h>
int main(void) {
(void) kqueue();
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for crypt()
----------------------------------------
checking for F_READAHEAD
objs/autotest.c: In function 'main':
objs/autotest.c:7:14: error: 'F_READAHEAD' undeclared (first use in this function)
7 | fcntl(0, F_READAHEAD, 1);;
| ^~~~~~~~~~~
objs/autotest.c:7:14: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <fcntl.h>
int main(void) {
fcntl(0, F_READAHEAD, 1);;
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for posix_fadvise()
----------------------------------------
checking for O_DIRECT
----------------------------------------
checking for F_NOCACHE
objs/autotest.c: In function 'main':
objs/autotest.c:7:14: error: 'F_NOCACHE' undeclared (first use in this function)
7 | fcntl(0, F_NOCACHE, 1);;
| ^~~~~~~~~
objs/autotest.c:7:14: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <fcntl.h>
int main(void) {
fcntl(0, F_NOCACHE, 1);;
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for directio()
In file included from objs/autotest.c:5:
/usr/include/sys/fcntl.h:1:2: warning: #warning redirecting incorrect #include <sys/fcntl.h> to <fcntl.h> [-Wcpp]
1 | #warning redirecting incorrect #include <sys/fcntl.h> to <fcntl.h>
| ^~~~~~~
objs/autotest.c: In function 'main':
objs/autotest.c:8:5: warning: implicit declaration of function 'directio' [-Wimplicit-function-declaration]
8 | directio(0, DIRECTIO_ON);;
| ^~~~~~~~
objs/autotest.c:8:17: error: 'DIRECTIO_ON' undeclared (first use in this function)
8 | directio(0, DIRECTIO_ON);;
| ^~~~~~~~~~~
objs/autotest.c:8:17: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/fcntl.h>
int main(void) {
directio(0, DIRECTIO_ON);;
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for statfs()
----------------------------------------
checking for statvfs()
----------------------------------------
checking for dlopen()
----------------------------------------
checking for sched_yield()
----------------------------------------
checking for sched_setaffinity()
----------------------------------------
checking for SO_SETFIB
objs/autotest.c: In function 'main':
objs/autotest.c:7:31: error: 'SO_SETFIB' undeclared (first use in this function)
7 | setsockopt(0, SOL_SOCKET, SO_SETFIB, NULL, 0);
| ^~~~~~~~~
objs/autotest.c:7:31: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <sys/socket.h>
int main(void) {
setsockopt(0, SOL_SOCKET, SO_SETFIB, NULL, 0);
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for SO_REUSEPORT
----------------------------------------
checking for SO_ACCEPTFILTER
objs/autotest.c: In function 'main':
objs/autotest.c:7:31: error: 'SO_ACCEPTFILTER' undeclared (first use in this function); did you mean 'SO_LOCK_FILTER'?
7 | setsockopt(0, SOL_SOCKET, SO_ACCEPTFILTER, NULL, 0);
| ^~~~~~~~~~~~~~~
| SO_LOCK_FILTER
objs/autotest.c:7:31: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <sys/socket.h>
int main(void) {
setsockopt(0, SOL_SOCKET, SO_ACCEPTFILTER, NULL, 0);
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for SO_BINDANY
objs/autotest.c: In function 'main':
objs/autotest.c:7:31: error: 'SO_BINDANY' undeclared (first use in this function)
7 | setsockopt(0, SOL_SOCKET, SO_BINDANY, NULL, 0);
| ^~~~~~~~~~
objs/autotest.c:7:31: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <sys/socket.h>
int main(void) {
setsockopt(0, SOL_SOCKET, SO_BINDANY, NULL, 0);
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for IP_TRANSPARENT
----------------------------------------
checking for IP_BINDANY
objs/autotest.c: In function 'main':
objs/autotest.c:8:31: error: 'IP_BINDANY' undeclared (first use in this function)
8 | setsockopt(0, IPPROTO_IP, IP_BINDANY, NULL, 0);
| ^~~~~~~~~~
objs/autotest.c:8:31: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <sys/socket.h>
#include <netinet/in.h>
int main(void) {
setsockopt(0, IPPROTO_IP, IP_BINDANY, NULL, 0);
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for IP_BIND_ADDRESS_NO_PORT
----------------------------------------
checking for IP_RECVDSTADDR
objs/autotest.c: In function 'main':
objs/autotest.c:8:31: error: 'IP_RECVDSTADDR' undeclared (first use in this function); did you mean 'IP_ORIGDSTADDR'?
8 | setsockopt(0, IPPROTO_IP, IP_RECVDSTADDR, NULL, 0);
| ^~~~~~~~~~~~~~
| IP_ORIGDSTADDR
objs/autotest.c:8:31: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <sys/socket.h>
#include <netinet/in.h>
int main(void) {
setsockopt(0, IPPROTO_IP, IP_RECVDSTADDR, NULL, 0);
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for IP_SENDSRCADDR
objs/autotest.c: In function 'main':
objs/autotest.c:8:31: error: 'IP_SENDSRCADDR' undeclared (first use in this function)
8 | setsockopt(0, IPPROTO_IP, IP_SENDSRCADDR, NULL, 0);
| ^~~~~~~~~~~~~~
objs/autotest.c:8:31: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <sys/socket.h>
#include <netinet/in.h>
int main(void) {
setsockopt(0, IPPROTO_IP, IP_SENDSRCADDR, NULL, 0);
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for IP_PKTINFO
----------------------------------------
checking for IPV6_RECVPKTINFO
----------------------------------------
checking for TCP_DEFER_ACCEPT
----------------------------------------
checking for TCP_KEEPIDLE
----------------------------------------
checking for TCP_FASTOPEN
----------------------------------------
checking for TCP_INFO
----------------------------------------
checking for accept4()
----------------------------------------
checking for kqueue AIO support
objs/autotest.c: In function 'main':
objs/autotest.c:8:56: error: 'SIGEV_KEVENT' undeclared (first use in this function)
8 | iocb.aio_sigevent.sigev_notify = SIGEV_KEVENT;
| ^~~~~~~~~~~~
objs/autotest.c:8:56: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <aio.h>
int main(void) {
struct aiocb iocb;
iocb.aio_sigevent.sigev_notify = SIGEV_KEVENT;
(void) aio_read(&iocb);
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for Linux AIO support
----------------------------------------
checking for int size
----------------------------------------
checking for long size
----------------------------------------
checking for long long size
----------------------------------------
checking for void * size
----------------------------------------
checking for uint32_t
----------------------------------------
checking for uint64_t
----------------------------------------
checking for sig_atomic_t
----------------------------------------
checking for sig_atomic_t size
----------------------------------------
checking for socklen_t
----------------------------------------
checking for in_addr_t
----------------------------------------
checking for in_port_t
----------------------------------------
checking for rlim_t
----------------------------------------
checking for uintptr_t
----------------------------------------
checking for system byte ordering
----------------------------------------
checking for size_t size
----------------------------------------
checking for off_t size
----------------------------------------
checking for time_t size
----------------------------------------
checking for AF_INET6
----------------------------------------
checking for setproctitle()
objs/autotest.c: In function 'main':
objs/autotest.c:7:5: warning: implicit declaration of function 'setproctitle' [-Wimplicit-function-declaration]
7 | setproctitle("test");;
| ^~~~~~~~~~~~
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /tmp/ccHfgGoM.o: in function `main':
/usr/src/nginx-1.20.2/objs/autotest.c:7: undefined reference to `setproctitle'
collect2: error: ld returned 1 exit status
----------
#include <sys/types.h>
#include <unistd.h>
#include <stdlib.h>
int main(void) {
setproctitle("test");;
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for pread()
----------------------------------------
checking for pwrite()
----------------------------------------
checking for pwritev()
----------------------------------------
checking for strerrordesc_np()
objs/autotest.c: In function 'main':
objs/autotest.c:7:18: warning: implicit declaration of function 'strerrordesc_np' [-Wimplicit-function-declaration]
7 | char *p; p = strerrordesc_np(0);
| ^~~~~~~~~~~~~~~
objs/autotest.c:7:16: warning: assignment to 'char *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
7 | char *p; p = strerrordesc_np(0);
| ^
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /tmp/ccGjoHpc.o: in function `main':
/usr/src/nginx-1.20.2/objs/autotest.c:7: undefined reference to `strerrordesc_np'
collect2: error: ld returned 1 exit status
----------
#include <sys/types.h>
#include <unistd.h>
#include <string.h>
int main(void) {
char *p; p = strerrordesc_np(0);
if (p == NULL) return 1;
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for sys_nerr
objs/autotest.c: In function 'main':
objs/autotest.c:8:18: error: 'sys_nerr' undeclared (first use in this function)
8 | printf("%d", sys_nerr);;
| ^~~~~~~~
objs/autotest.c:8:18: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <errno.h>
#include <stdio.h>
int main(void) {
printf("%d", sys_nerr);;
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for _sys_nerr
objs/autotest.c: In function 'main':
objs/autotest.c:8:18: error: '_sys_nerr' undeclared (first use in this function)
8 | printf("%d", _sys_nerr);;
| ^~~~~~~~~
objs/autotest.c:8:18: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
#include <errno.h>
#include <stdio.h>
int main(void) {
printf("%d", _sys_nerr);;
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for localtime_r()
----------------------------------------
checking for clock_gettime(CLOCK_MONOTONIC)
----------------------------------------
checking for posix_memalign()
----------------------------------------
checking for memalign()
----------------------------------------
checking for mmap(MAP_ANON|MAP_SHARED)
----------------------------------------
checking for mmap("/dev/zero", MAP_SHARED)
----------------------------------------
checking for System V shared memory
----------------------------------------
checking for POSIX semaphores
----------------------------------------
checking for struct msghdr.msg_control
----------------------------------------
checking for ioctl(FIONBIO)
----------------------------------------
checking for ioctl(FIONREAD)
----------------------------------------
checking for struct tm.tm_gmtoff
----------------------------------------
checking for struct dirent.d_namlen
objs/autotest.c: In function 'main':
objs/autotest.c:8:29: error: 'struct dirent' has no member named 'd_namlen'; did you mean 'd_name'?
8 | struct dirent dir; dir.d_namlen = 0;
| ^~~~~~~~
| d_name
objs/autotest.c:9:42: error: 'struct dirent' has no member named 'd_namlen'; did you mean 'd_name'?
9 | printf("%d", (int) dir.d_namlen);
| ^~~~~~~~
| d_name
----------
#include <sys/types.h>
#include <unistd.h>
#include <dirent.h>
#include <stdio.h>
int main(void) {
struct dirent dir; dir.d_namlen = 0;
printf("%d", (int) dir.d_namlen);
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for struct dirent.d_type
----------------------------------------
checking for sysconf(_SC_NPROCESSORS_ONLN)
----------------------------------------
checking for sysconf(_SC_LEVEL1_DCACHE_LINESIZE)
objs/autotest.c: In function 'main':
objs/autotest.c:7:13: error: '_SC_LEVEL1_DCACHE_LINESIZE' undeclared (first use in this function)
7 | sysconf(_SC_LEVEL1_DCACHE_LINESIZE);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
objs/autotest.c:7:13: note: each undeclared identifier is reported only once for each function it appears in
----------
#include <sys/types.h>
#include <unistd.h>
int main(void) {
sysconf(_SC_LEVEL1_DCACHE_LINESIZE);
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -o objs/autotest objs/autotest.c -Wl,--as-needed,-O1,--sort-common
----------
----------------------------------------
checking for openat(), fstatat()
----------------------------------------
checking for getaddrinfo()
----------------------------------------
checking for psol
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(83.string_util.o.o): in function `base::snprintf(char*, unsigned long, char const*, ...)':
string_util.cc:(.text._ZN4base8snprintfEPcmPKcz[_ZN4base8snprintfEPcmPKcz]+0x8d): undefined reference to `__vsnprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(1.safe_strerror_posix.o.o): in function `safe_strerror(int)':
safe_strerror_posix.cc:(.text._Z13safe_strerrori+0x4e): undefined reference to `__strncat_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(1.stringprintf.o.o): in function `void base::(anonymous namespace)::StringAppendVT<std::string>(std::string*, std::string::value_type const*, __va_list_tag*)':
stringprintf.cc:(.text._ZN4base12_GLOBAL__N_1L14StringAppendVTISsEEvPT_PKNS2_10value_typeEP13__va_list_tag+0x82): undefined reference to `__vsnprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: stringprintf.cc:(.text._ZN4base12_GLOBAL__N_1L14StringAppendVTISsEEvPT_PKNS2_10value_typeEP13__va_list_tag+0xf1): undefined reference to `__vsnprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: stringprintf.cc:(.text._ZN4base12_GLOBAL__N_1L14StringAppendVTISsEEvPT_PKNS2_10value_typeEP13__va_list_tag+0x1b2): undefined reference to `__vsnprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(1.stringprintf.o.o): in function `void base::(anonymous namespace)::StringAppendVT<std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> > >(std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >*, std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::value_type const*, __va_list_tag*)':
stringprintf.cc:(.text._ZN4base12_GLOBAL__N_1L14StringAppendVTISbIwSt11char_traitsIwESaIwEEEEvPT_PKNS6_10value_typeEP13__va_list_tag+0x75): undefined reference to `__vswprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: stringprintf.cc:(.text._ZN4base12_GLOBAL__N_1L14StringAppendVTISbIwSt11char_traitsIwESaIwEEEEvPT_PKNS6_10value_typeEP13__va_list_tag+0x116): undefined reference to `__vswprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: stringprintf.cc:(.text._ZN4base12_GLOBAL__N_1L14StringAppendVTISbIwSt11char_traitsIwESaIwEEEEvPT_PKNS6_10value_typeEP13__va_list_tag+0x1b4): undefined reference to `__vswprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(88.html_keywords.o.o): in function `google::sparsetable<std::pair<std::string const, char const*>, (unsigned short)48, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::set(unsigned long, std::pair<std::string const, char const*> const&)':
html_keywords.cc:(.text._ZN6google11sparsetableISt4pairIKSsPKcELt48ENS_27libc_allocator_with_reallocIS5_EEE3setEmRKS5_[_ZN6google11sparsetableISt4pairIKSsPKcELt48ENS_27libc_allocator_with_reallocIS5_EEE3setEmRKS5_]+0x360): undefined reference to `__fprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(88.html_keywords.o.o): in function `std::vector<google::sparsegroup<std::pair<std::string const, char const*>, (unsigned short)48, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >, google::libc_allocator_with_realloc<google::sparsegroup<std::pair<std::string const, char const*>, (unsigned short)48, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > > > >::_M_default_append(unsigned long)':
html_keywords.cc:(.text._ZNSt6vectorIN6google11sparsegroupISt4pairIKSsPKcELt48ENS0_27libc_allocator_with_reallocIS6_EEEENS7_IS9_EEE17_M_default_appendEm[_ZNSt6vectorIN6google11sparsegroupISt4pairIKSsPKcELt48ENS0_27libc_allocator_with_reallocIS6_EEEENS7_IS9_EEE17_M_default_appendEm]+0x2f5): undefined reference to `__fprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(88.html_keywords.o.o): in function `google::sparse_hashtable<std::pair<std::string const, char const*>, std::string, net_instaweb::CasePreserveStringHash, google::sparse_hash_map<std::string, char const*, net_instaweb::CasePreserveStringHash, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SelectKey, google::sparse_hash_map<std::string, char const*, net_instaweb::CasePreserveStringHash, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SetKey, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::sparse_hashtable(google::sparse_hashtable<std::pair<std::string const, char const*>, std::string, net_instaweb::CasePreserveStringHash, google::sparse_hash_map<std::string, char const*, net_instaweb::CasePreserveStringHash, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SelectKey, google::sparse_hash_map<std::string, char const*, net_instaweb::CasePreserveStringHash, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SetKey, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::MoveDontCopyT, google::sparse_hashtable<std::pair<std::string const, char const*>, std::string, net_instaweb::CasePreserveStringHash, google::sparse_hash_map<std::string, char const*, net_instaweb::CasePreserveStringHash, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SelectKey, google::sparse_hash_map<std::string, char const*, net_instaweb::CasePreserveStringHash, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SetKey, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >&, unsigned long)':
html_keywords.cc:(.text._ZN6google16sparse_hashtableISt4pairIKSsPKcESsN12net_instaweb22CasePreserveStringHashENS_15sparse_hash_mapISsS4_S7_St8equal_toISsENS_27libc_allocator_with_reallocIS5_EEE9SelectKeyENSD_6SetKeyESA_SC_EC2ENSG_13MoveDontCopyTERSG_m[_ZN6google16sparse_hashtableISt4pairIKSsPKcESsN12net_instaweb22CasePreserveStringHashENS_15sparse_hash_mapISsS4_S7_St8equal_toISsENS_27libc_allocator_with_reallocIS5_EEE9SelectKeyENSD_6SetKeyESA_SC_EC5ENSG_13MoveDontCopyTERSG_m]+0x13b8): undefined reference to `__fprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(88.html_keywords.o.o): in function `google::sparse_hash_map<std::string, char const*, net_instaweb::CasePreserveStringHash, std::equal_to<std::string>, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::operator[](std::string const&)':
html_keywords.cc:(.text._ZN6google15sparse_hash_mapISsPKcN12net_instaweb22CasePreserveStringHashESt8equal_toISsENS_27libc_allocator_with_reallocISt4pairIKSsS2_EEEEixERS9_[_ZN6google15sparse_hash_mapISsPKcN12net_instaweb22CasePreserveStringHashESt8equal_toISsENS_27libc_allocator_with_reallocISt4pairIKSsS2_EEEEixERS9_]+0x179a): undefined reference to `__fprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(88.html_keywords.o.o): in function `google::sparse_hashtable<std::pair<std::string const, char const*>, std::string, net_instaweb::CaseFoldStringHash, google::sparse_hash_map<std::string, char const*, net_instaweb::CaseFoldStringHash, net_instaweb::CaseFoldStringEqual, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SelectKey, google::sparse_hash_map<std::string, char const*, net_instaweb::CaseFoldStringHash, net_instaweb::CaseFoldStringEqual, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SetKey, net_instaweb::CaseFoldStringEqual, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::sparse_hashtable(google::sparse_hashtable<std::pair<std::string const, char const*>, std::string, net_instaweb::CaseFoldStringHash, google::sparse_hash_map<std::string, char const*, net_instaweb::CaseFoldStringHash, net_instaweb::CaseFoldStringEqual, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SelectKey, google::sparse_hash_map<std::string, char const*, net_instaweb::CaseFoldStringHash, net_instaweb::CaseFoldStringEqual, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SetKey, net_instaweb::CaseFoldStringEqual, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::MoveDontCopyT, google::sparse_hashtable<std::pair<std::string const, char const*>, std::string, net_instaweb::CaseFoldStringHash, google::sparse_hash_map<std::string, char const*, net_instaweb::CaseFoldStringHash, net_instaweb::CaseFoldStringEqual, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SelectKey, google::sparse_hash_map<std::string, char const*, net_instaweb::CaseFoldStringHash, net_instaweb::CaseFoldStringEqual, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >::SetKey, net_instaweb::CaseFoldStringEqual, google::libc_allocator_with_realloc<std::pair<std::string const, char const*> > >&, unsigned long)':
html_keywords.cc:(.text._ZN6google16sparse_hashtableISt4pairIKSsPKcESsN12net_instaweb18CaseFoldStringHashENS_15sparse_hash_mapISsS4_S7_NS6_19CaseFoldStringEqualENS_27libc_allocator_with_reallocIS5_EEE9SelectKeyENSC_6SetKeyES9_SB_EC2ENSF_13MoveDontCopyTERSF_m[_ZN6google16sparse_hashtableISt4pairIKSsPKcESsN12net_instaweb18CaseFoldStringHashENS_15sparse_hash_mapISsS4_S7_NS6_19CaseFoldStringEqualENS_27libc_allocator_with_reallocIS5_EEE9SelectKeyENSC_6SetKeyES9_SB_EC5ENSF_13MoveDontCopyTERSF_m]+0x13b8): undefined reference to `__fprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(88.html_keywords.o.o):html_keywords.cc:(.text._ZN12net_instaweb12HtmlKeywords19InitEscapeSequencesEv+0x2865): more undefined references to `__fprintf_chk' follow
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(136.url_canon_internal.o.o): in function `url_canon::_itoa_s(int, char*, unsigned long, int)':
url_canon_internal.cc:(.text._ZN9url_canon7_itoa_sEiPcmi+0x3d): undefined reference to `__snprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(136.url_canon_internal.o.o): in function `url_canon::_itow_s(int, unsigned short*, unsigned long, int)':
url_canon_internal.cc:(.text._ZN9url_canon7_itow_sEiPtmi+0x65): undefined reference to `__snprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.ucnv.o.o): in function `_fromUnicodeWithCallback':
ucnv.c:(.text._fromUnicodeWithCallback+0x30d): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: ucnv.c:(.text._fromUnicodeWithCallback+0x41c): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.ucnv.o.o): in function `_toUnicodeWithCallback':
ucnv.c:(.text._toUnicodeWithCallback+0x3b5): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: ucnv.c:(.text._toUnicodeWithCallback+0x4e3): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.ucnv.o.o): in function `pagespeed_ol_ucnv_convertEx_46':
ucnv.c:(.text.ucnv_convertEx_46+0x7c4): undefined reference to `__rawmemchr'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.ucnv.o.o): in function `ucnv_internalConvert':
ucnv.c:(.text.ucnv_internalConvert+0x1e6): undefined reference to `__rawmemchr'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.ucnv_bld.o.o): in function `internalSetName':
ucnv_bld.c:(.text.internalSetName+0x116): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.ucnv_lmb.o.o): in function `_LMBCSToUnicodeWithOffsets':
ucnv_lmb.c:(.text._LMBCSToUnicodeWithOffsets+0x99): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.putil.o.o): in function `pagespeed_ol_uprv_getDefaultCodepage_46':
putil.c:(.text.uprv_getDefaultCodepage_46+0x152): undefined reference to `__strncpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.ucnv2022.o.o): in function `UConverter_toUnicode_ISO_2022_KR_OFFSETS_LOGIC':
ucnv2022.c:(.text.UConverter_toUnicode_ISO_2022_KR_OFFSETS_LOGIC+0x2bc): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.ucnv_ext.o.o): in function `pagespeed_ol_ucnv_extInitialMatchFromU_46':
ucnv_ext.c:(.text.ucnv_extInitialMatchFromU_46+0x1af): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.ucnv_ext.o.o): in function `pagespeed_ol_ucnv_extContinueMatchFromU_46':
ucnv_ext.c:(.text.ucnv_extContinueMatchFromU_46+0x13d): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.unistr.o.o): in function `icu_46::UnicodeString::cloneArrayIfNeeded(int, int, signed char, int**, signed char)':
unistr.cpp:(.text._ZN6icu_4613UnicodeString18cloneArrayIfNeededEiiaPPia+0x1c4): undefined reference to `__memmove_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.locid.o.o): in function `icu_46::Locale::operator=(icu_46::Locale const&)':
locid.cpp:(.text._ZN6icu_466LocaleaSERKS0_+0xb6): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: locid.cpp:(.text._ZN6icu_466LocaleaSERKS0_+0xc8): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: locid.cpp:(.text._ZN6icu_466LocaleaSERKS0_+0xda): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: locid.cpp:(.text._ZN6icu_466LocaleaSERKS0_+0x120): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uloc.o.o): in function `_getKeywords.part.0':
uloc.c:(.text._getKeywords.part.0+0x519): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uloc.o.o): in function `pagespeed_ol_uloc_acceptLanguageFromHTTP_46':
uloc.c:(.text.uloc_acceptLanguageFromHTTP_46+0x3b6): undefined reference to `__sprintf_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uloc_tag.o.o): in function `pagespeed_ol_uloc_toLanguageTag_46':
uloc_tag.c:(.text.uloc_toLanguageTag_46+0x92e): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uloc_tag.c:(.text.uloc_toLanguageTag_46+0xa0e): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uloc_tag.c:(.text.uloc_toLanguageTag_46+0xbf4): undefined reference to `__stpcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uloc_tag.c:(.text.uloc_toLanguageTag_46+0x1094): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uloc_tag.c:(.text.uloc_toLanguageTag_46+0x12fc): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uloc_tag.o.o): in function `pagespeed_ol_uloc_forLanguageTag_46':
uloc_tag.c:(.text.uloc_forLanguageTag_46+0xc94): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uloc_tag.c:(.text.uloc_forLanguageTag_46+0xd7b): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uloc_tag.c:(.text.uloc_forLanguageTag_46+0xde9): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresbund.o.o): in function `init_entry':
uresbund.c:(.text.init_entry+0x81): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.init_entry+0x26d): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresbund.o.o): in function `entryOpen':
uresbund.c:(.text.entryOpen+0xa8): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.entryOpen+0x28a): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.entryOpen+0x567): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresbund.o.o): in function `init_resb_result.part.4':
uresbund.c:(.text.init_resb_result.part.4+0x835): undefined reference to `__rawmemchr'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresbund.o.o): in function `pagespeed_ol_ures_getByKeyWithFallback_46':
uresbund.c:(.text.ures_getByKeyWithFallback_46+0x1bd): undefined reference to `__strncpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresbund.o.o): in function `pagespeed_ol_ures_getFunctionalEquivalent_46':
uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x1dd): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x1ed): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x278): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x329): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x339): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresbund.o.o):uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x38f): more undefined references to `__strcpy_chk' follow
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresbund.o.o): in function `pagespeed_ol_ures_getFunctionalEquivalent_46':
uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x45a): undefined reference to `__stpcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x4d3): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x5d3): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x63f): undefined reference to `__stpcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x655): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x692): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x6a7): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x6b7): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x6fe): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresbund.o.o):uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x7cc): more undefined references to `__strcpy_chk' follow
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresbund.o.o): in function `pagespeed_ol_ures_getFunctionalEquivalent_46':
uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x878): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x9ab): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0x9ff): undefined reference to `__memcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0xa5b): undefined reference to `__stpcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0xa71): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0xa8b): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0xb6f): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0xc11): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: uresbund.c:(.text.ures_getFunctionalEquivalent_46+0xc33): undefined reference to `__strcpy_chk'
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a(125.uresdata.o.o): in function `pagespeed_ol_res_findResource_46':
uresdata.c:(.text.res_findResource_46+0x14e): undefined reference to `__rawmemchr'
collect2: error: ld returned 1 exit status
----------
#include <sys/types.h>
#include <unistd.h>
#include "pagespeed/kernel/base/string.h"
#include "pagespeed/kernel/base/string_writer.h"
#include "pagespeed/kernel/base/null_message_handler.h"
#include "pagespeed/kernel/html/html_parse.h"
#include "pagespeed/kernel/html/html_writer_filter.h"
int main() {
GoogleString output_buffer;
net_instaweb::StringWriter write_to_string(&output_buffer);
net_instaweb::NullMessageHandler handler;
net_instaweb::HtmlParse html_parse(&handler);
net_instaweb::HtmlWriterFilter html_writer_filter(&html_parse);
html_writer_filter.set_writer(&write_to_string);
html_parse.AddFilter(&html_writer_filter);
html_parse.StartParse("http:example.com");
html_parse.ParseText(
"<html ><body ><h1 >Test</h1 ><p>Test Text</p></body></html>\n");
html_parse.FinishParse();
printf("parsed as: %s", output_buffer.c_str());
return 0;
}
----------
cc -Os -fomit-frame-pointer -g -D_GLIBCXX_USE_CXX11_ABI=0 --std=c++11 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/chromium/src -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/google-sparsehash/src/src -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/google-sparsehash/gen/arch/linux/x64/include -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/grpc/src/include -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/protobuf/src/src -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/re2/src -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/out/Release/obj/gen -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/out/Release/obj/gen/protoc_out/instaweb -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/apr/src/include -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/aprutil/src/include -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/apr/gen/arch/linux/x64/include -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/third_party/aprutil/gen/arch/linux/x64/include -I /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/include/url -o objs/autotest objs/autotest.cc -Wl,--as-needed,-O1,--sort-common /usr/src/incubator-pagespeed-ngx-1.14.33.1-RC1/psol/lib/Release/linux/x64/pagespeed_automatic.a -lstdc++ -lrt -pthread -lm -luuid
----------
Please help me check it. What's wrong with it?
the build error in your case is caused by the undefined references, which in turn are caused by an outdated build environment. I had the very same error with default gcc-Version 4.8.5 on centos 7 and solved it by updating to version 7+ using slc:
yum -y install centos-release-scl
yum -y install devtoolset-7-gcc* devtoolset-7-binutils
scl enable devtoolset-7 bash
gcc -v
[resp. your build command]
I get a PSOL error....
And when i download the package with a PSOL folder i still get a PSOL error.... I don't get what is wrong.....