• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

sqlite 2 , wher is it ?

M

marlon@

Guest
hi , i have CENT os 5 x86_64 , i nead to publish some site with the sitebuilder to the server , i have now sqlite 3 on the server , but i nead sqlite 2 , i have tried to look for a solution in the forums but cant see any weare to down load sqlite 2 , for that particular OS , any ideas ?

thank you for your time.
 
Having the same issue... PHP5 uses 3 and I know the libraries are named different so in theory you could run both at the same time.
 
As I understand this question already unswered in these threads:

http://forum.swsoft.com/showthread.php?t=51230&highlight=sqlite
http://forum.swsoft.com/showthread.php?t=51256&highlight=sqlite

Currently sqlite2 should be used on publishing side. You should note that on published server package sqlite2 itself should be installed together with PHP sqlite extension. There is no problem to find appropriate sqlite2 package for your OS (for example, on http://rpm.pbone.net). As for PHP extension, compiled packages exist not for all PHP versions, so in most cases sqlite.so extension should be compiled manually. You can use the link which 'marlon' provided above.
 
ha, unbelievable, indeed the solution was here

http://www.phpbuilder.com/board/archive/index.php/t-10307306.html

wget -q http://pecl.php.net/get/SQLite-1.0.3.tgz

then unpacked and began to compile it

$ tar zxvf SQLite-1.0.3.tgz
$ cd SQLite-1.0.3
$ phpize
$ ./configure
$ make

make failed here with some offset error

edit sqlite.c, comment out the following line:
/* static unsigned char arg3_force_ref[] = {3, BYREF_NONE, BYREF_NONE, BYREF_FORCE }; */

And then change these lines

function_entry sqlite_functions[] = {
PHP_FE(sqlite_open, arg3_force_ref)
PHP_FE(sqlite_popen, arg3_force_ref)
to:
function_entry sqlite_functions[] = {
PHP_FE(sqlite_open, third_arg_force_ref)
PHP_FE(sqlite_popen, third_arg_force_ref)


$ make
$ make install

make install plopped the .so into the correct directory without need of this

$ cp modules/sqlite.so /usr/lib/php/modules
$ /sbin/service/httpd restart

it worked wonderfully for me
 
Back
Top