Bug #80579 [Opn]: Can't build php if there is a space in the containing folder
Edit report at https://bugs.php.net/bug.php?id=80579&edit=1
ID: 80579
Updated by: nikic@php.net
Reported by: fmichaut74 at gmail dot com
Summary: Can't build php if there is a space in the
containing folder
Status: Open
Type: Bug
Package: Compile Failure
Operating System: Linux - Fedora 31
PHP Version: 8.0.0
Block user comment: N
Private report: N
New Comment:
I tried to add quotes to the include paths, but:
configure:40308: cc -o conftest -I"/usr/include/valgrind" -I"/home/nikic/php/with
whitespace/ext/date/lib" -I"/usr/include/libxml2"
-I"/usr/include/x86_64-linux-gnu" -I"/usr/include/enchant-2"
-I"/usr/include/glib-2.0" -I"/usr/lib/x86_64-linux-gnu/glib-2.0/include"
-I"/usr/include/libpng16" -I"/usr/include/freetype2" -g -fvisibility=hidden -O0
-Wl,-rpath,/build/libjpeg-turbo-6HlDLQ/libjpeg-turbo-2.0.3/obj-x86_64-linux-gnu/lib/x86_64-linux-gnu
-L/build/libjpeg-turbo-6HlDLQ/libjpeg-turbo-2.0.3/obj-x86_64-linux-gnu/lib/x86_64-linux-gnu
conftest.c -lgmp -lbz2 -lutil -lrt -lm -ldl -lxml2 -lssl -lcrypto -lsqlite3 -lz -lcurl -lxml2
-lenchant-2 -lffi -lssl -lcrypto -lz -lpng16 -lz -lwebp -ljpeg -lXpm -lX11 -lfreetype >&5
cc: error: whitespace/ext/date/lib": No such file or directory
Even with -I"/home/nikic/php/with whitespace/ext/date/lib" it seems to get interpreted as
a separate directly when running in configure. The same command works when running from the shell :/
Previous Comments:
------------------------------------------------------------------------
[2021-01-03 17:09:13] fmichaut74 at gmail dot com
Description:
------------
Downloaded php 8.0 at https://www.php.net/distributions/php-8.0.0.tar.gz.
I downloaded it in a directory with spaces in it.
When I tried to execute the configure script, I got the following error :
configure: error: iconv does not support errno
Strangely enough, even though this message doesn't seems to be a naming error, the error
disapeared when I tried to compile in a path without any spaces in directory names, so it really is
an issue with the directory name.
Then I wanted to try to compile without iconv to see if it was the only issue.
I ran ./configure --without-iconv. The configure step failed with the following error
message :
/configure: line 59362: test: /tmp/temp/hello: binary operator expected
I edited the configure script to fix it, just added some quotes around variables to make the test
command succeed. After that, the configure step completed successfully (despite some warnings about
sed not finding files).
But when I tried to make, there was errors tied to the directory name containing spaces.
Test script:
---------------
mkdir "hello world"
cd "hello world"
wget https://www.php.net/distributions/php-8.0.0.tar.gz
taf -xf php-8.0.0.tar.gz
cd php-8.0.0
./configure
make
# I tried the exact same steps but with a directory named HelloWorld and i was able to build php,
the errors only occurs with a space in the directory name
Expected result:
----------------
I was expecting to be able to build php no matter how the previous directories are named.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=80579&edit=1
Thread (5 messages)