i've tried:
1. edit php.ini
extension=rar.so
2. run this command
gunzip rar-xxx.tgz
tar -xvf rar-xxx.tar
cd rar-xxx
phpize
./configure && make && make install
but i got error in phpize. command not found
Main Topics
Browse All Topicsdear all,
i'm using rar_open() function and running well at localhost (using Windows XP and XAMPP), but when i try at server, it returns error:
Fatal error: Call to undefined function rar_open()
i have debian + LAMPP installed in server.
i guess this is config issue or no rar installed in server. any solution (prefer step by step since i'm not really familiar with linux) to solve this problem?
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
did you actually install the php rar extension?
type in console php -i | grep rar and post the return here
if you do not have the extension installed I think you need to install it as a part of the PECL Repository.
So you need to install the pecl php package, which you will probably need to hunt down from the pecl website? I am on a RPM based system and I have the pecl package in repository. An google search suggests you need to get the dh-make-php package then run that and install php.
Anyway once you have got PECL working you can just run the commaond pecl -install rar in the console
dear again all, i have my phpize installed. then i try these steps from linux command prompt:
1. gunzip rar-xxx.tgz
2. tar -xvf rar-xxx.tar
3. cd rar-xxx
4. /opt/lampp/bin/phpize
5. ./configure && make && make install
in step 4: it return error:
grep: /opt/lampp/include/php/mai
grep: /opt/lampp/include/php/Zen
grep: /opt/lampp/include/php/Zen
Configuring for:
PHP Api Version:
Zend Module Api No:
Zend Extension Api No:
Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF
environment variable is set correctly and then rerun this script.
if i try this command:
/opt/lampp/bin/php -i|grep rar
then it returns:
include_path => .:/opt/lampp/htdocs/librar
iconv library version => 2.3.6
Ming SWF output library => enabled
Library version => FreeTDS
Client API library version => 5.0.51a
ncurses library version => 5.3
PCRE Library Version => 7.3 2007-08-28
PDO Driver for MySQL, client library version => 5.0.51a
SQLite Library => 3.3.17
SQLite Library => 2.8.17
Regex Library => Bundled library enabled
Dynamic Library Support => enabled
PWD => /opt/lampp/htdocs/editoria
_SERVER["PWD"] => /opt/lampp/htdocs/editoria
_ENV["PWD"] => /opt/lampp/htdocs/editoria
any advice what i should do?
thanks,
i run this command: apt-get install rar
it returns:
Reading package lists... Done
Building dependency tree... Done
Suggested packages:
unrar
The following NEW packages will be installed:
rar
0 upgraded, 1 newly installed, 0 to remove and 63 not upgraded.
Need to get 506kB of archives.
After unpacking 1036kB of additional disk space will be used.
Get:1 http://kambing.ui.edu etch/non-free rar 1:3.7b1-2 [506kB]
Fetched 506kB in 14m44s (572B/s)
Selecting previously deselected package rar.
(Reading database ... 21698 files and directories currently installed.)
Unpacking rar (from .../rar_1%3a3.7b1-2_i386.d
Setting up rar (3.7b1-2) ...
then i restart apache, try to run my script, it still return error message:
Fatal error: Call to undefined function rar_open()
then i run command: /opt/lampp/bin/phpize
it returns:
grep: /opt/lampp/include/php/mai
grep: /opt/lampp/include/php/Zen
grep: /opt/lampp/include/php/Zen
Configuring for:
PHP Api Version:
Zend Module Api No:
Zend Extension Api No:
Cannot find autoconf. Please check your autoconf installation and the $PHP_AUTOCONF
environment variable is set correctly and then rerun this script.
what should i do now? thanks a lot.
thanks, i think now i have installed php-devel properly.
i try this:
apt-get install rar
Reading package lists... Done
Building dependency tree... Done
rar is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 61 not upgraded.
so i assume rar is already installed.
i restart my apache, but still cannot use rar function. any clue?
i think i already have php-dev installed.
this is what i got from command apt-get install php5-dev:
maen:~# apt-get install php-dev
Reading package lists... Done
Building dependency tree... Done
E: Couldn't find package php-dev
maen:~# apt-get install php5-dev
Reading package lists... Done
Building dependency tree... Done
php5-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 61 not upgraded.
and this is what i got from type command:
/opt/lampp/bin/pecl -v install rar (something wrong in result as you can see below)
maen:~# /opt/lampp/bin/pecl -v install rar
downloading rar-1.0.0.tgz ...
Starting to download rar-1.0.0.tgz (134,904 bytes)
.....done: 134,904 bytes
md5sum ok: /opt/lampp/lib/php/test/ra
md5sum ok: /opt/lampp/lib/php/test/ra
md5sum ok: /opt/lampp/lib/php/test/ra
md5sum ok: /opt/lampp/lib/php/test/ra
md5sum ok: /opt/lampp/lib/php/test/ra
md5sum ok: /opt/lampp/lib/php/test/ra
md5sum ok: /opt/lampp/lib/php/doc/rar
md5sum ok: /opt/lampp/lib/php/doc/rar
md5sum ok: /opt/lampp/lib/php/doc/rar
md5sum ok: /opt/lampp/lib/php/doc/rar
121 source files, building
building in /tmp/pear/cache/rar-1.0.0
running: phpize
grep: /opt/lampp/include/php/mai
grep: /opt/lampp/include/php/Zen
grep: /opt/lampp/include/php/Zen
Configuring for:
PHP Api Version:
Zend Module Api No:
Zend Extension Api No:
rolling back 30 file operations
ERROR: `phpize' failed
maen:~#
maen:~#
this is the result when i type locate phpize
maen:/opt/lampp/htdocs/edi
/opt/lampp/bin/phpiz
/opt/lamp
/o
/opt/
m
i read that manual rar installation just like this:
Example 1. Rar installation
gunzip rar-xxx.tgz
tar -xvf rar-xxx.tar
cd rar-xxx
phpize
./configure && make && make install
i've got problem when running this line:
./configure && make && make install
it returns:
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for a sed that does not truncate output... /bin/sed
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc and cc understand -c and -o together... yes
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking target system type... i686-pc-linux-gnu
checking for PHP prefix... /usr
checking for PHP includes... -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/da
chec
checking for PHP installed headers prefix... /usr/include/php5
checking for re2c... no
configure: WARNING: You will need re2c 0.9.11 or later if you want to regenerate PHP parsers.
checking for gawk... no
checking for nawk... nawk
checking if nawk is broken... no
checking whether to enable rar support... yes, shared
checking for g++... no
checking for c++... no
checking for gpp... no
checking for aCC... no
checking for CC... no
checking for cxx... no
checking for cc++... no
checking for cl.exe... no
checking for FCC... no
checking for KCC... no
checking for RCC... no
checking for xlC_r... no
checking for xlC... no
checking whether we are using the GNU C++ compiler... no
checking whether g++ accepts -g... no
checking how to run the C++ preprocessor... /lib/cpp
configure: error: C++ preprocessor "/lib/cpp" fails sanity check
See `config.log' for more details.
FYI when i type rar or unrar, the command is ready. but i still get my page error
Fatal error: Call to undefined function rar_open()
when running rar_open function.
Business Accounts
Answer for Membership
by: uetian1707Posted on 2008-07-14 at 22:48:21ID: 22004388
Hi,
com/showth read.php?p =5183783 orums/inde x.php? acti on=profile ;u=32999;s a=showPost s /PHP-Extra cting-Firs t-Characte r- xumU6Amy .html
Please read the below:
http://www.webhostingtalk.
http://www.phpfreaks.com/f
http://www.bigresource.com