Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 149670 - New package: dev-php5/php-gtk-2.0.0_alpha
Summary: New package: dev-php5/php-gtk-2.0.0_alpha
Status: VERIFIED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Anant Narayanan (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 154683
  Show dependency tree
 
Reported: 2006-09-30 16:42 UTC by Anant Narayanan (RETIRED)
Modified: 2007-03-06 15:54 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
php-gtk-2.0.0.ebuild (New package) (php-gtk-2.0.0.ebuild,1.69 KB, text/plain)
2006-09-30 16:44 UTC, Anant Narayanan (RETIRED)
Details
php-gtk-2.0.0.ebuild (New package - Modified as per comments) (php-gtk-2.0.0.ebuild,1.99 KB, text/plain)
2006-10-01 11:14 UTC, Anant Narayanan (RETIRED)
Details
Patch to allow building mozembed against Firefox (gtkmozembed.patch,1.41 KB, patch)
2006-10-01 11:15 UTC, Anant Narayanan (RETIRED)
Details | Diff
New ebuild with extra options (php-gtk-2.0.0.ebuild,2.00 KB, text/plain)
2006-11-10 07:40 UTC, Matthew Schultz
Details
Ebuild update (php-gtk-2.0.0.ebuild,2.00 KB, text/plain)
2006-11-10 08:04 UTC, Matthew Schultz
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Anant Narayanan (RETIRED) gentoo-dev 2006-09-30 16:42:12 UTC
Hi!

Here's an ebuild for the alpha release of PHP-GTK 2. PHP-GTK 2 is the Gtk+2 binding for PHP.

It should most probably go into dev-php/php-gtk, even though it requires PHP 5.1.2 upwards to run.

I ran several tests with this ebuild on my x86 system, with all possible combinations of USE flags; all of them were successful.

Cheers,
Anant
Comment 1 Anant Narayanan (RETIRED) gentoo-dev 2006-09-30 16:44:04 UTC
Created attachment 98485 [details]
php-gtk-2.0.0.ebuild (New package)
Comment 2 Sebastian Bergmann (RETIRED) gentoo-dev 2006-10-01 00:58:33 UTC
I tried the ebuild and it works, however:

  1. We should not automatically enable this extension (ie. add it to the
     configuration file for PHP CLI. Running PHP CLI with php-gtk loaded as
     root causes the PHP interpreter to die on startup.

  2. I am not comfortable with the mozilla dependency. It should be possible
     to build this package against Mozilla Firefox.

  3. I am not sure we need all the USE flags.
Comment 3 Jakub Moc (RETIRED) gentoo-dev 2006-10-01 01:00:39 UTC
(In reply to comment #2)
>   2. I am not comfortable with the mozilla dependency. It should be possible
>      to build this package against Mozilla Firefox.

+1, mozilla is not acceptable. firefox and seamonkey is the way to go, optimally it should compile against both of them. Mozilla needs to be removed from portage.
Comment 4 Anant Narayanan (RETIRED) gentoo-dev 2006-10-01 11:11:37 UTC
>   1. We should not automatically enable this extension (ie. add it to the
>      configuration file for PHP CLI. Running PHP CLI with php-gtk loaded as
>      root causes the PHP interpreter to die on startup.

Agreed. ebuild modified accordingly.
 
>   2. I am not comfortable with the mozilla dependency. It should be possible
>      to build this package against Mozilla Firefox.

Done, also pushed upstream.

>   3. I am not sure we need all the USE flags.

Which ones? nolibglade is required because libglade is built by default, but sometimes you may not want libglade support.  sourceview and mozembed add support for the GtkSourceView and GtkMozEmbed widgets. (BTW, I've already left out the scintilla USE flag even though it's included in the release, since we haven't decided to include it or not in the final PHP-GTK 2 release yet)
Comment 5 Anant Narayanan (RETIRED) gentoo-dev 2006-10-01 11:14:48 UTC
Created attachment 98535 [details]
php-gtk-2.0.0.ebuild (New package - Modified as per comments)
Comment 6 Anant Narayanan (RETIRED) gentoo-dev 2006-10-01 11:15:28 UTC
Created attachment 98536 [details, diff]
Patch to allow building mozembed against Firefox
Comment 7 Matthew Schultz 2006-11-10 07:40:04 UTC
Created attachment 101606 [details]
New ebuild with extra options

I added ~amd64 to the ebuild and changed the dependency to seamonkey.  Mozilla is old and isn't secure so it shouldn't even be a dependency anymore.  Also note, that if you have the pecl-apd extension enabled for php-cli, it will not emerge.  You need to disable the extension temporarily by commenting it out in /etc/php/cli-php5/ext/apd.ini. I've e-mailed upstream about this problem so I hope they will fix it.  If someone wants to build a patch for the ebuild, be my guest.  The problem line is in the configure file and is this:

PHP_SAPI=`$PHP --version | sed -n 's/.*(\(...\)).*/\1/p'`

When APD is enabled, it will output:

cli
APD

When APD is disabled, it will output:

cli

It obviously doesn't like the second line.
Comment 8 Matthew Schultz 2006-11-10 07:43:48 UTC
I forgot to mention that it emerged fine on amd64 arch and seems to be working ok.
Comment 9 Anant Narayanan (RETIRED) gentoo-dev 2006-11-10 07:57:44 UTC
Hi Matthew,

Some comments:

- Why the dependency on seamonkey? Upstream doesn't even support it yet...

- The ebuild fetches php-gtk-2.0.0alpha which doesn't have firefox support yet (its only in CVS), commenting the epatch isn't right!

- The pecl-apd bug is new. Although we haven't recieved any bug report yet at upstream, we'll look into it.

Thanks!
Comment 10 Matthew Schultz 2006-11-10 08:04:06 UTC
Created attachment 101607 [details]
Ebuild update

Sorry, when I couldn't get it to emerge with APD, I commented out the patch to test but forgot to reenable it since it doesn't have problems with that.  It still shouldn't even depend on mozilla.  If it worked with mozilla, why wouldn't it with seamonkey?  seamonkey is basically just mozilla 1.8.
Comment 11 Matthew Schultz 2006-11-10 08:18:34 UTC
As far as I can tell, Seamonkey supports gtk2:

http://www.mozilla.org/projects/seamonkey/releases/seamonkey1.0.6/installation.html
Comment 12 Anant Narayanan (RETIRED) gentoo-dev 2006-11-10 08:21:39 UTC
> As far as I can tell, Seamonkey supports gtk2:

Seamonkey has a gtkmozembed component but unfortunately the soname of the library is different for firefox, seamonkey and mozilla.

Do a `pkg-config --list-all | grep mozembed' and you'll see what I mean.

We need to add seamonkey support specifically to PHP-GTK 2, which I haven't done yet; but will in the near future. In any case the php-gtk2alpha tarball doesn't have either firefox or seamonkey support in it.
Comment 13 Jory A. Pratt 2006-11-10 08:30:09 UTC
(In reply to comment #11)
> As far as I can tell, Seamonkey supports gtk2:
> 
> http://www.mozilla.org/projects/seamonkey/releases/seamonkey1.0.6/installation.html
> 

of course seamonkey supports gtk2 is is designed around firefox-1.5.x ... the only similiarity between it and mozilla is the gecko-sdk engine is 1.8. This does not belong in tree until a better understanding of mozilla products is reached by all parties.
Comment 14 Matthew Schultz 2006-11-10 08:34:05 UTC
The ebuild also needs to be modified to enable the extension by setting up the php_gtk2.ini file.  If I get some more free time, I'll see if I can get that to work.
Comment 15 Matthew Schultz 2006-11-10 08:35:20 UTC
I'd say forget about the mozembed support until later just so it can get into portage now.  It's annoying to have to emerge php4 just to use pptpconfig.
Comment 16 Anant Narayanan (RETIRED) gentoo-dev 2006-11-10 08:44:42 UTC
> The ebuild also needs to be modified to enable the extension by setting up the
> php_gtk2.ini file.  If I get some more free time, I'll see if I can get that to
> work.

Please read the entire history of a bug before adding to it!

I had included support for enabling the extension automatically in my first ebuild, but removed it because of Sebastian's perfectly reasonable comment.
Comment 17 Anant Narayanan (RETIRED) gentoo-dev 2006-11-10 08:46:31 UTC
> I'd say forget about the mozembed support until later just so it can get into
> portage now.  It's annoying to have to emerge php4 just to use pptpconfig.

FYI, pptpconfig will NOT work out-of-the-box with PHP-GTK 2. It needs to be ported. 

Comment 18 Matthew Schultz 2006-11-10 08:58:21 UTC
(In reply to comment #16)
> > The ebuild also needs to be modified to enable the extension by setting up the
> > php_gtk2.ini file.  If I get some more free time, I'll see if I can get that to
> > work.
> 
> Please read the entire history of a bug before adding to it!
> 
> I had included support for enabling the extension automatically in my first
> ebuild, but removed it because of Sebastian's perfectly reasonable comment.
> 

Sorry.  I read it and I don't know what he's talking about.  My cli works just fine on cli.  I ran a few tests and it doesn't choke on anything.  I even ran php-gtk code without issue.  ????


> FYI, pptpconfig will NOT work out-of-the-box with PHP-GTK 2. It needs to be
> ported.

Yup I e-mailed upstream about this.  I'm going to see if I can get to work by modding it myself.   
Comment 19 Matthew Schultz 2006-11-10 08:59:42 UTC
Blah, sorry, php5 works just fine on cli with php-gtk enabled.
Comment 20 Anant Narayanan (RETIRED) gentoo-dev 2006-11-10 09:07:07 UTC
> Blah, sorry, php5 works just fine on cli with php-gtk enabled.

NOT if you don't have an X server running. Please do a little research before making conclusive statements. 

Comment 21 Kfir Ozer 2007-01-20 10:05:47 UTC
i need to remove !nolibglade? for the ebuild to properly digest.
Comment 22 Anant Narayanan (RETIRED) gentoo-dev 2007-02-20 20:34:10 UTC
http://packages.gentoo.org/ebuilds/?php-gtk-2.0.0_alpha
Comment 23 Matthew Schultz 2007-02-20 20:41:10 UTC
What about an AMD64 keyword?
Comment 24 Anant Narayanan (RETIRED) gentoo-dev 2007-02-20 20:51:59 UTC
(In reply to comment #23)
> What about an AMD64 keyword?

Will be addressed by the AMD64 arch team, see bug #167793