For some reason when I attempt to configure phc-0.2.0.3 oh my machine (Fedora Linux localhost.localdomain 2.6.34.6-47.fc13.i686 #1 SMP Fri Aug 27 09:48:44 UTC 2010 i686 i686 i386 GNU/Linux) I get the following error:
checking for boostlib >= 1.34.0... configure: error: We could not detect the boost libraries (version 1.34 or higher). If you have a staged boost library (still not installed) please specify $BOOST_ROOT in your environment and do not give a PATH to --with-boost option. If you are sure you have boost installed, then check your version number looking in <boost/version.hpp>. See http://randspringer.de/boost for more documentation.
Boost is installed to /usr/include/boost. I tried setting the environment variable as specified in the error to $BOOST_ROOT=/usr/include/boost and when that didn't work i tried $BOOST_ROOT=/usr/include. Once I did that I tried
./configure --with-boost
and
./configure
Both times I got the same error. Here is the site for phc:
http://www.phpcompiler.org/
The boost site is here:
http://www.randspringer.de/boost/ucl.html
Has anyone had this issue before?
I recompiled PHP and installed it. That resolved the issue.
Related
I'm trying to follow the cron job setup as seen in the documentation but I keep running into an issue. In the command line it output all of the markup in the header.php with the following statements at the end:
<h1>An Error Was Encountered</h1>
<p>The MongoDB PECL extension has not been installed or enabled</p>
What I'm typing into the command line:
php index.php tools message
Is there something I need to install on the server? Here are my specs from pecl version.
PEAR Version: 1.9.4
PHP Version: 5.3.10-1ubuntu3.15
Zend Engine Version: 2.3.0
Running on: Linux lucrum 3.8.0-29-generic #42~precise1-Ubuntu SMP Wed Aug 14 16:19:23 UTC 2013 x86_64
I don't have the rep to add this as a comment so i have to post as an answer. But judging from what you posted the error message is telling you that the MongoDB PECL extension hasn't been installed on your server. Have you checked to see if it actualy is installed? If it is then you need to look into your configuration.
I would ask in Chat, but I don't have enough points yet.
I am trying to migrate a server from a deployed setting to a virtual machine running in virtualbox. All networking works fine in the virtual machine. I have no problem posting the code, but I think it is too large and too many files.
I am completely lost. I have
Installed Ubuntu Server (updated etc)
Installed php, apache, mysql, phpmyadmin, etc
ssh'd into the current server
copied the files using tar -zcvf ./html_files_copy.tar.gz ./html/*
copied mysql stuff using mysqldump -uroot -p --all-databases > db_copy.sql
deployed both the html / php files and the mysql database
No matter what I do though, the server generates a blank page. I have looked into this as much as I can figure out and it seems that php is failing on parsing the php code.
How can I fix this and have the php not fail, and why would it work on one machine and not the other? I can copy the stuff back to the old server and it WORKS!? Mysql tables look EXACTLY the same too.
Does it make sense that the completely blank page (debug info is turned on, not sure why it doesn't say anything) is a parsing error caused by the newer PHP not knowing one version older functions anymore?
Is there a list somewhere I can use to search the code for suspect functions?
To get the following info I used phpinfo() in a php file, lsb_release -a and uname -a from terminal using ssh
- New Server
PHP Version 5.5.9-1ubuntu4.5 with Apache/2.4.7
Ubuntu 14.04.01
mysql Client API version 5.5.40
Linux ubuntu 3.13.0-32-generic #57-Ubuntu SMP Tue Jul 15 03:51:08 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
- Old Server
PHP Version
5.5.9-1ubuntu4.4, with Apache/2.4.7
on Ubuntu 14.04
mysql Client API version 5.5.40
Linux linuxdesk 3.13.0-34-generic #60-Ubuntu SMP Wed Aug 13 15:45:27 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
Check the PHP log-file or enable error display using the display_errors flag. Also enable logging of all errors: error_reporting(E_ALL); and verify these settings with phpinfo().
I think what I need to know is how to specify the build architecture when building .php extensions on OSX.
What are the likely architectures that I should try first, and how to specify them?
The details:
I am having trouble building a working mssql.so php extension for my server.
I have been using an AMPPS server on mac to serve php based websites, accessing MySQL databases.
Now I need to connect to an MSSQL database. The AMPPS php installation does not include the mssql extension so when I try to use mssql_connect() I get the following error.
Call to undefined function `mssql_connect()` in /Applications/AMPPS/www/test.php
I think I need to add mssql.so to the php/lib/extensions/ext folder and then add
extension=mssql.so
to my php.ini file.
To build mssql.so I have found a couple of online tutorials that both use Freetds:
http://lkrms.org/php-with-freetds-on-os-x-mavericks/#comment-82521
http://blog.benjaminwalters.net/?p=10
I used home brew to install autoconf:
brew instal autoconf
Then I downloaded and installed freetds:
./configure --prefix=/usr/local/freetds --sysconfdir=/usr/local/freetds/conf/freetds --disable-libiconv --disable-odbc
make
sudo make install
Freetds was installed at /usr/local/freetds. Then I downloaded php. I have tried this with all the versions available for download 5.6.2, 5.5.18, 5.4.32 and 5.3.29. 5.3.29 had a problem and I could not generate mssql.so.
All of the other versions successfuly produced mssql.so using the following method:
Unzip package in downloads folder
cd php-5.4.17/ext/mssql
phpize
./configure --with-php-config=/usr/bin/php-config --with-mssql=/usr/local/freetds
make
Then I copy the generated mssql.so to /Applications/AMPPS/php-5.4/lib/extensions/ext and add this to the php.ini file.
extension=mssql.so
I restart the apache server and view the error / log file which has the following error:
PHP Warning: PHP Startup: Unable to load dynamic library '/Applications/AMPPS/php-5.4/lib/extensions/ext/mssql.so' - dlopen(/Applications/AMPPS/php-5.4/lib/extensions/ext/mssql.so, 9): no suitable image found. Did find:\n\t/Applications/AMPPS/php-5.4/lib/extensions/ext/mssql.so: mach-o, but wrong architecture in Unknown on line 0
So it seems like I have built mssql.so for the wrong architecture?
I looked at the terminal output when I configure the "make" for mssql.so and found the following indicating the architecture it is being made for:
checking build system type... i386-apple-darwin13.1.0
checking host system type... i386-apple-darwin13.1.0
checking target system type... i386-apple-darwin13.1.0
So it looks like I made it for i386. This is where I start to get confused.
After make the terminal instructs me to run "make test", I do this and receive the following output:
=====================================================================
PHP : /usr/bin/php PHP_SAPI : cli PHP_VERSION : 5.4.24
ZEND_VERSION: 2.4.0 PHP_OS : Darwin - Darwin myMac13.1.0 Darwin
Kernel Version 13.1.0:
Thu Jan 16 19:40:37 PST 2014;
root:xnu-2422.90.20~2/RELEASE_X86_64 x86_64
INI actual : /Users/user/downloads/php-5.6.2/ext/mssql/tmp-php.ini More .INIs :
CWD : /Users/user/Downloads/php-5.6.2/ext/mssql Extra dirs :
VALGRIND:Notused
===================================================================TIME START 2014-10-26 11:53:50
=====================================================================
No tests were run. It does not say why no tests were run which is frustrating. It mentions x86_64 which is not i386.
I tried to check what architecture my system is to verify if it should be i386 or x86_64.
I did this with uname and arch as follows:
uname -p
i368
uname -m
x86_64
arch
i386
So my machine hardware is x86_64 (uname -m) but the processor architecture is i386 (uname -p) I don't understand how these can be different or what the implications of this are.
So have I built mssql.so for the wrong architecture or have I done something else wrong? If I have built it for the wrong architecture then how do I configure it to build for the correct one?
Many thanks for any help with this.
First off I am not sure if I am at the right place or better at serverfault.
I am working on a PHP project and need access to an Oracle 10g DB. The server I am using is provided and maintained from a 3rd party. Lets call them ABC. I have only a restricted user. So everytime I need something I have to ask them to install it. This worked fine until now.
The server is a RedHat server and ABC is only allowed to install software from the official repositories. We were able to install the Oracle Instant Client but did not find the PHP libraries within the repository.
Our second try was to find a rpm-package containing the OCI8 library which is compatible with the installed software. Unfortunatly we only found a version which needs a newer PHP version which, you guessed it, is not part of the official repository.
Okay, I checken php.net and they told me that I would be able to compile it myself as a shared library. Neat, that would be enough. The problem here is that i am not able to run the phpize command as locking failes (in terms of blocks) the process. The root-User from ABC would be able to do it, but they are not allowed to compile anything.
So here I am asking you guys if there is a way to download the files and use it as a shared library without installing, compiling or whetever. The server is a 64bit RedHat Enterprise 6:
Linux [SERVERNAME] 2.6.32-358.11.1.el6.x86_64 #1 SMP Wed May 15 10:48:38 EDT 2013 x86_64 x86_64 x86_64 GNU/Linux
Any help is highly appreciated!
Thanks,
Alex
I found a way:
1. Set a proxy for pear:
pear config-set http_proxy http://[proxy]:[port]
2. Get sudo rights to use pecl
3. Install:
sudo pecl install oci8
I'm trying to get eAccelerator 0.9.6.1 installed to speed up my Magento site.
Pretty vanilla install per the directions here:
http://docs.moodle.org/24/en/Installing_eAccelerator_In_Ubuntu_Server
Unfortunately, php -v does not show eAccelerator, and apache error log shows on restart after install:
[eAccelerator] This build of "eAccelerator" was compiled for PHP version 5.3.10-1ubuntu3.7. Rebuild it for your PHP version (5.3.10-1ubuntu3.8) or download precompiled binaries.
/usr/bin/php-config shows
version="5.3.10-1ubuntu3.8"
make test says
PHP : /usr/bin/php
PHP_SAPI : cli
PHP_VERSION : 5.3.10-1ubuntu3.8
ZEND_VERSION: 2.3.0
PHP_OS : Linux - Linux libatio 3.2.0-29-generic #46-Ubuntu SMP Fri Jul 27 17:04:05 UTC 2012 i686
phpinfo shows eAccelerator section with nothing enabled.
eAccelerator control.php shows no data.
What am I missing here? Seems I am compiling for the correct php, but apache disagrees?
Thanks,
C
No secret here except repeated reinstall with another copy of the same distro, although in the meantime I also installed Zend Optimizer and IonCube php loader.
Cheers ,
C