Solved lang/php55-extensions "make config" error

Mayhem30

Well-Known Member

Reaction score: 19
Messages: 392

I'm trying to prepare to upgrade to PHP 5.5 and running in to an issue. When I try to do a make config in the lang/php55-extensions directory, this is what I'm seeing :

Is there a new way to select which extensions we would like to use?
Code:
/usr/ports/lang/php55-extensions]$ sudo make config

make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uyes}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uctype}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Udom}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Ufilter}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uhash}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uiconv}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Ujson}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uopcache}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Updo}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Updo_sqlite}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uphar}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uposix}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Usession}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Usimplexml}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Usqlite3}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Utokenizer}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uxml}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uxmlreader}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 346: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uxmlwriter}} != "")
make: Fatal errors encountered -- cannot continue
make: stopped in /usr/ports/lang/php55-extensions
This happens for me as well in the lang/php56-extensions directory.
 

derekschrock

Member

Reaction score: 34
Messages: 80

I believe this was fixed this morning:

commit dd08cfc82fc5ed5c719ebf891f5c97f533d26744
Author: miwi <miwi@FreeBSD.org>
Date: Thu Feb 18 12:05:45 2016 +0000

bsd.php.mk
- Unbreak build for php70
- Cleanup php55/6 extenions
- Put not existing php70 extentions to php55 and php56 extra defines

lang/php70
- Remove mysqli from pdo_mysql it's looping here and does not really depends on mysqli
- Bump PORTREVISION

This work has been done in collaboration with
- fluffy@
- Franco Fichtner
 
OP
OP
M

Mayhem30

Well-Known Member

Reaction score: 19
Messages: 392

my /etc/make.conf contains :
Code:
CPUTYPE?=core-avx2
OPTIONS_UNSET=X11
MAKE_JOBS_NUMBER=8
WITH_POSTFIX=yes
WITH_OPENSSL_PORT=yes
 
OP
OP
M

Mayhem30

Well-Known Member

Reaction score: 19
Messages: 392

Ok, so what can I do to fix this then?

I've ran portnsap fetch update again this morning and still have this issue.
 
OP
OP
M

Mayhem30

Well-Known Member

Reaction score: 19
Messages: 392

I don't need to delete anything first? It will just overwrite everything?
 

bagas

Active Member

Reaction score: 1
Messages: 101

I have the sameproblem!
did.
Code:
# portsnap fetch extract update
Code:
# uname -rm
10.1-RELEASE-p27 amd64
Code:
# php -v
PHP 5.4.45 (cli) (built: Sep 11 2015 15:55:02)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2014 Zend Technologies
  with XCache v3.2.0, Copyright (c) 2005-2014, by mOo
  with XCache Cacher v3.2.0, Copyright (c) 2005-2014, by mOo
Code:
# make config
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uyes}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uctype}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Udom}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Ufilter}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uhash}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uiconv}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Ujson}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uopcache}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Updo}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Updo_sqlite}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uphar}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uposix}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Usession}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Usimplexml}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Usqlite3}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Utokenizer}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uxml}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uxmlreader}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uxmlwriter}} != "")
make: Fatal errors encountered -- cannot continue
make: stopped in /usr/ports/lang/php55-extensions
Code:
# portupgrade -arR
[Reading data from pkg(8) ... - 113 packages found - done]
[Updating the portsdb <format:bdb_btree> in /usr/ports ... - 25734 port entries found .........1000.........2000.........3000.........4000.........5000.........6000.........7000.........8000.........9000.........10000.........11000.........12000.........13000.........14000.........15000.........16000.........17000.........18000.........19000.........20000.........21000.........22000.........23000.........24000.........25000....... ..... done]
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Uzlib}} != "")
make: "/usr/ports/Mk/bsd.php.mk" line 342: Malformed conditional (${_USE_PHP_VER${PHP_VER}:M${:Usession}} != "")
make: Fatal errors encountered -- cannot continue** Makefile possibly broken: databases/pecl-memcache:
** Please report this to the maintainer for databases/pecl-memcache

  make: stopped in /usr/ports/databases/pecl-memcache
/usr/local/sbin/portupgrade:1575:in `get_pkgname': Makefile broken (MakefileBrokenError)
  from /usr/local/sbin/portupgrade:637:in `block (4 levels) in main'
  from /usr/local/sbin/portupgrade:621:in `each'
  from /usr/local/sbin/portupgrade:621:in `block (3 levels) in main'
  from /usr/local/sbin/portupgrade:594:in `catch'
  from /usr/local/sbin/portupgrade:594:in `block (2 levels) in main'
  from /usr/local/lib/ruby/2.1/optparse.rb:1403:in `call'
  from /usr/local/lib/ruby/2.1/optparse.rb:1403:in `block (2 levels) in parse_in_order'
  from /usr/local/lib/ruby/2.1/optparse.rb:1398:in `catch'
  from /usr/local/lib/ruby/2.1/optparse.rb:1398:in `block in parse_in_order'
  from /usr/local/lib/ruby/2.1/optparse.rb:1346:in `catch'
  from /usr/local/lib/ruby/2.1/optparse.rb:1346:in `parse_in_order'
  from /usr/local/lib/ruby/2.1/optparse.rb:1340:in `order!'
  from /usr/local/lib/ruby/2.1/optparse.rb:1332:in `order'
  from /usr/local/sbin/portupgrade:571:in `block in main'
  from /usr/local/lib/ruby/2.1/optparse.rb:880:in `initialize'
  from /usr/local/sbin/portupgrade:238:in `new'
  from /usr/local/sbin/portupgrade:238:in `main'
  from /usr/local/sbin/portupgrade:2380:in `<main>`
 

derekschrock

Member

Reaction score: 34
Messages: 80

With lang/php5 removed from the ports tree (maybe lang/php54 as well I forgot the meta port mess that was lang/php5*) if you have php 5.4 installed /usr/ports/Mk/bsd.php.mk will try to use /usr/local/etc/php.conf to find your php version with the contents of that file. PHP_VER=5 if you have 5.4 installed.

$ cat /usr/local/etc/php.conf
PHP_VER=5
PHP_VERSION=5.4.45
PHP_SAPI=cli cgi
PHP_EXT_INC=pcre spl


One of our bad lines:
Code:
...
342 .  if ${_USE_PHP_VER${PHP_VER}:M${extension}} != ""$   
...
I believe the above fails to resolve (or whatever make would call it) since there isn't a _USE_PHP_VER5 var in Mk/bsd.php.mk.

Code:
...
  1 _USE_PHP_VER55= ${_USE_PHP_ALL} mssql mysql sybase_ct$   
257 _USE_PHP_VER56= ${_USE_PHP_ALL} mssql mysql sybase_ct$   
  1 _USE_PHP_VER70= ${_USE_PHP_ALL}$ 
...
I'm thinking to fix this for people that build ports on a non-poudriere system and if lang/php5 (5.4 is incorrectly set as the default) is installed is one of the following:
- uninstall lang/php5
- install your matching lang/php* version: lang/php55 lang/php56 or lang/php70
- move ${PHPBASE}/etc/php.conf out of the way
- Change ${PHPBASE}/etc/php.conf to be a supported version (not recommended)

retry make config
 
Top