2

I am attempting to spin up PHPBrew and installing PHP 5.5.38 (I know - it's old and we shouldn't be using it but I have little say in the matter!)

Running:

phpbrew install 5.5.38 

Runs into the following error:

/home/me/.phpbrew/build/php-5.5.38/ext/openssl/openssl.c:4991:17: 
error: storage size of ‘cipher_ctx’ isn’t known

EVP_CIPHER_CTX cipher_ctx;

             ^~~~~~~~~~

Makefile:524: recipe for target 'ext/openssl/openssl.lo' failed

make: *** [ext/openssl/openssl.lo] Error 1

I came across a solution at https://github.com/phpbrew/phpbrew/issues/939 which suggests downgrading openssl. I am a bit reluctant to do this - brand new shiny install and all - Ubuntu 18.04 - and it seems counter-intuitive to downgrade parts of a system for a tool that I was hoping to use alongside existing packages (rather than have to send them backwards).

I'm no PHPBrew expert but is it just the libssl-dev that is needed to make this work? Is there a way of obtaining the relevant dev files, letting PHPBrew know of these and not interfere with my current version of openssl?

Zakalwe
  • 1,444
  • 3
  • 14
  • 25
  • You can't use a crazy old PHP on a new Ubuntu. Use a similarly vintage Ubuntu (16.04?). If they suggest downgrading OpenSSL, which is something you absolutely *need* to have patched, that's a bad plan. Upgrade your PHP or get a waiver *in writing* that you can deploy an old, possibly vulnerable version of OpenSSL. – tadman Jun 05 '18 at 16:53
  • I did wonder if it was even possible. The site in question now has a critical piece of functionality simply not working despite months of me advising to upgrade sooner rather than wait for armageddon. Are there any other options. Virtual machine perhaps? Failing that I could spin up something on AWS. Was hoping to avoid that however. – Zakalwe Jun 05 '18 at 21:03
  • If you're not using virtualized servers to start with you're already on shaky ground. A hypervisor like VMWare, VirtualBox, Proxmox, KVM, XCP or Hyper-V is an essential component of your architecture. Being able to freeze, clone, and restore your instances helps in so many ways. – tadman Jun 05 '18 at 21:14
  • I have the same issue. I'm on Ubuntu 18.04, I have two project, one use php56 and the others php7. When I build php56 it said the same error, and searching on the internet, tells me the openssl version (1.1.0) not compatible when build php56, the solution is to downgrade, but It's not clear how to downgrade openssl. – Erick Jun 27 '18 at 01:04
  • @Erick tadman is correct. I ended up spinning up a VM and using a previous version of Ubuntu. Virtualbox on Ubuntu worked well for me. – Zakalwe Jun 27 '18 at 11:37

0 Answers0