views:

925

answers:

3

I have an application that works pretty well in Ubuntu, Windows and the Xandros that come with the Asus EeePC.

Now we are moving to the Acer Aspire One but I'm having a lot of trouble making php-gtk to compile under the Fedora-like (Linpus Linux Lite) Linux that come with it.

A: 

If you could give us more to go on than just trouble making it compile; we might be better able to help you with your issues.

X-Istence
Yeah i was just thinking that, My first approach with this question was to leave a nice how-to page. I'll ask again with an specific problem and after resolve that and compile successfully, I'll go back to this page and make that nice how-to with the whole process not just the problem.
levhita
+1  A: 

Hi Guys well I finally got this thing to work the basic workflow was this:

#!/bin/bash
sudo yum install yum-utils
#We don't want to update the main gtk2 by mistake so we download them
#manually and install with no-deps[1](and forced because gtk version
#version of AA1 and the gtk2-devel aren't compatible).
sudo yumdownloader --disablerepo=updates gtk2-devel glib2-devel
sudo rpm --force --nodeps -i gtk2*rpm glib2*rpm

#We install the rest of the libraries needed.
sudo yum --disablerepo=updates install atk-devel pango-devel libglade2-devel
sudo yum install php-cli php-devel make gcc

#We Download and compile php-gtk
wget http://gtk.php.net/do_download.php?download_file=php-gtk-2.0.1.tar.gz
tar -xvzf php-gtk-2.0.1.tar.gz
cd php-gtk-2.0.1
./buildconf
./configure
make
sudo make install

If you want to add more libraries like gtk-extra please type ./configure -help before making it to see the different options available.

After installing you'll need to add php_gtk2.so to the Dynamic Extensions of /etc/php.ini

extension=php_gtk2.so

Sources:

[1]: Dependency problems on Acer Aspire One Linux

levhita
A: 

I managed to get all components needed for Phoronix test suite installed on Fedora but still have one issue.

phoronix-test-suite gui

shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory pwd: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory pwd: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory /usr/bin/phoronix-test-suite: line 28: [: /usr/share/phoronix-test-suite: unary operator expected

You need two packages that aren't in Fedora, php-gtk, but php-gtk also has it's dependency - pecl-cairo

php-gtk needs to be downloaded from svn because tar.gz version is really old and doesn't work with php 5.3

Here is how I got all components built.

su -c "yum install php-cli php-devel make gcc gtk2-devel svn"

svn co [url]http://svn.php.net/repository/pecl/cairo/trunk[/url] pecl-cairo cd pecl-cairo/ phpize ./configure make su -c "make install"

cd ..

svn co [url]http://svn.php.net/repository/gtk/php-gtk/trunk[/url] php-gtk cd php-gtk ./buildconf ./configure make su -c "make install"

cd ..

wget [url]http://www.phoronix-test-suite.com/download.php?file=phoronix-test-suite-2.8.1[/url] tar xvzf phoronix-test-suite-2.8.1.tar.gz cd phoronix-test-suite su -c "./install-sh"

So please take where I left to get Phoronix test suite running on Fedora.

Valent Turkovic