You are not logged in.

#1 2007-03-07 21:31:25

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Problem to create a package the download of the source faild

I want to create package for php-gtk:
http://gtk.php.net/
http://www.kksou.com/php-gtk2/index.php
http://www.kksou.com/php-gtk2/articles/ … -linux.php
http://gtk.php.net/download.php

I did this PKGBUILD:

# Contributor: Nadav Vinik <nadavvin at gmail.com>
pkgname=php-gtk
pkgver=2.0.0a
pkgrel=1
pkgdesc="GTK+ binding to PHP"
depends=('')
source=(http://gtk.php.net/do_download.php?download_file=php-gtk-2.0.0alpha.tar.gz)
url="http://gtk.php.net"

build() {
        cd $startdir/src/$pkgname-$pkgver
        tar xvzf php-gtk-2.0.0alpha.tar.gz
        cd php-gtk-2.0.0
        ./buildconf --with-phpize=/usr/local/php-5.1.6/bin/phpize
        ./configure --prefix=/usr/local/php-gtk-2.01 --enable-sourceview --with-php-config=/usr/local/php-5.1.6/bin/php-config
        make || return 1
        make prefix=$startdir/pkg/usr install
}

The problem that It failed:

HTTP request sent, awaiting response... 416 Requested Range Not Satisfiable

    The file is already fully retrieved; nothing to do.

==> ERROR: Failed to download do_download.php?download_file=php-gtk-2.0.0alpha.tar.gz
==> Aborting...

Before that it download, however it failed immediately after it download.

What is the problem?

Offline

#2 2007-03-07 21:36:46

XazZ
Member
From: Munich, Germany
Registered: 2006-12-30
Posts: 72

Re: Problem to create a package the download of the source faild

Offline

#3 2007-03-07 21:41:05

SleepingGiant08
Member
From: Ellicott City, MD USA
Registered: 2007-01-10
Posts: 124

Re: Problem to create a package the download of the source faild

Yeah the problem is with your link, it's a php function... Like XazZ suggested, you need an alternate link that is not a php, asp, cfm, whatever..

btw make sure you fill in the depends=(), and md5sum


Registered Linux User #439761

Offline

#4 2007-03-07 21:45:57

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

thanks.

btw make sure you fill in the depends=(), and md5sum

I will do it in the end or when it failed without some of them.

I have problems with the paths:

./PKGBUILD: line 13: cd: php-gtk-2.0.0: No such file or directory
./PKGBUILD: line 14: ./buildconf: No such file or directory
./PKGBUILD: line 15: ./configure: No such file or directory
make: *** No targets specified and no makefile found.  Stop.
==> ERROR: Build Failed.  Aborting...
# ls src/php-gtk-2.0.0alpha/
AUTHORS              README               demos/
CODING_STANDARDS     README.KNOWN-ISSUES  ext/
COPYING.LIB          TODO2                generator/
ChangeLog            build2/              main/
INSTALL              buildconf            php_gtk.m4
NEWS                 buildconf.bat        test/
NEWS.pre-2-0         config.m4            win32/

Should I use /usr/local as they did or just /usr?

Last edited by nadavvin (2007-03-07 21:46:29)

Offline

#5 2007-03-07 21:52:16

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

I change to:

# Contributor: Nadav Vinik <nadavvin at gmail.com>
pkgname=php-gtk
pkgver=2.0.0alpha
pkgrel=1
pkgdesc="GTK+ binding to PHP"
depends=('')
source=(http://gtk.php.net/distributions/php-gtk-2.0.0alpha.tar.gz)
url="http://gtk.php.net"

build() {
        cd $startdir/src/$pkgname-$pkgver
        tar xvzf php-gtk-2.0.0alpha.tar.gz
        cd php-gtk-2.0.0
        ./buildconf --with-phpize=/usr/local/php-5.1.6/bin/phpize
        ./configure --prefix=/usr/local/php-gtk-2.01 --enable-sourceview --with-php-config=/usr/local/php-5.1.6/bin/php-config
        make || return 1
        make prefix=$startdir/pkg/usr install
}

but now:

# makepkg PKGBUILD 
==> Making package: php-gtk 2.0.0alpha-1 (Wed Mar  7 23:50:15 IST 2007)
==> Checking Runtime Dependencies...
==> Checking Buildtime Dependencies...
==> Retrieving Sources...
==>     Using local copy of php-gtk-2.0.0alpha.tar.gz
==> WARNING: MD5sums are missing or incomplete.  Cannot verify source integrity.
==> Extracting Sources...
==>     tar --use-compress-program=gzip -xf php-gtk-2.0.0alpha.tar.gz
==> Removing existing pkg/ directory...
==> Starting build()...
tar: php-gtk-2.0.0alpha.tar.gz: Cannot open: No such file or directory
tar: Error is not recoverable: exiting now
tar: Child returned status 2
tar: Error exit delayed from previous errors
./PKGBUILD: line 13: cd: php-gtk-2.0.0: No such file or directory
/bin/sh: /usr/local/php-5.1.6/bin/phpize: No such file or directory
make: *** [buildmk.stamp] Error 127
./PKGBUILD: line 15: ./configure: No such file or directory
make: *** No targets specified and no makefile found.  Stop.
==> ERROR: Build Failed.  Aborting...

Why does is not download this time?

I only change from a to alpha in the version.

Offline

#6 2007-03-07 21:52:59

SleepingGiant08
Member
From: Ellicott City, MD USA
Registered: 2007-01-10
Posts: 124

Re: Problem to create a package the download of the source faild

I edited your PKGBUILD, built for me:

# Contributor: Nadav Vinik <nadavvin at gmail.com>
pkgname=php-gtk
pkgver=2.0.0alpha
pkgrel=1
pkgdesc="GTK+ binding to PHP"
depends=(php gtk)
source=(http://gtk.php.net/distributions/php-gtk-2.0.0alpha.tar.gz)
url="http://gtk.php.net"

build() {
        cd $startdir/src/$pkgname-$pkgver
        ./buildconf --with-phpize=/usr/bin/phpize
        ./configure --prefix=/usr/bin --enable-sourceview 
--with-php-config=/usr/bin/php-config
        make || return 1
        make prefix=$startdir/pkg/usr install
}

problem was/is with your phpsize location... let me know if this works for you

*EDITremoved quotes in depends() and changed prefixes
, the package build and installs!

Last edited by SleepingGiant08 (2007-03-07 22:00:50)


Registered Linux User #439761

Offline

#7 2007-03-07 21:55:12

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

same problem as I change my script.

Offline

#8 2007-03-07 21:58:00

SleepingGiant08
Member
From: Ellicott City, MD USA
Registered: 2007-01-10
Posts: 124

Re: Problem to create a package the download of the source faild

nadavvin wrote:

same problem as I change my script.

should work I have built it twice. Copy and paste it from above..


Registered Linux User #439761

Offline

#9 2007-03-07 22:02:30

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

SleepingGiant08 wrote:
nadavvin wrote:

same problem as I change my script.

should work I have built it twice. Copy and paste it from above..

In which package there is the php-config?

configure: error: PHP-GTK 2.x requires GLib 2.6.0 or higher
./PKGBUILD: line 14: --with-php-config=/usr/local/php-5.1.6/bin/php-config: No such file or directory
make: *** No targets specified and no makefile found.  Stop.
==> ERROR: Build Failed.  Aborting..

Offline

#10 2007-03-07 22:08:57

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

I have it in

# locate php-config
/usr/bin/php-config

why it is in other place than you?

Why doesn't it find?

configure: error: PHP-GTK 2.x requires GLib 2.6.0 or higher
./PKGBUILD: line 14: --with-php-config=/usr/bin/php-config: No such file or directory
make: *** No targets specified and no makefile found.  Stop.
==> ERROR: Build Failed.  Aborting...

Last edited by nadavvin (2007-03-07 22:11:53)

Offline

#11 2007-03-07 22:10:45

SleepingGiant08
Member
From: Ellicott City, MD USA
Registered: 2007-01-10
Posts: 124

Re: Problem to create a package the download of the source faild

nadavvin wrote:

I have it in

# locate php-config
/usr/bin/php-config

why it is in other place than you?

Ii isn't I didnt see that when I first posted, it was updated before your last post... If you copy and paste it now, it should work. Does it build and install?


Registered Linux User #439761

Offline

#12 2007-03-07 22:13:26

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

Ii isn't I didnt see that when I first posted, it was updated before your last post... If you copy and paste it now, it should work. Does it build and install?

No, and I use your version.

I copy your edit post and still I get:

configure: error: PHP-GTK 2.x requires GLib 2.6.0 or higher
./PKGBUILD: line 14: --with-php-config=/usr/bin/php-config: No such file or directory
make: *** No targets specified and no makefile found.  Stop.
==> ERROR: Build Failed.  Aborting...
[root@myhost tmp]# ls -l /usr/bin/php-config 
-rwxr-xr-x 1 root root 1265 2007-02-13 19:55 /usr/bin/php-config

What is the problem?

Last edited by nadavvin (2007-03-07 22:32:06)

Offline

#13 2007-03-07 22:29:46

SleepingGiant08
Member
From: Ellicott City, MD USA
Registered: 2007-01-10
Posts: 124

Re: Problem to create a package the download of the source faild

paste your PKGBUILD, because the one I posted works for me and we have the same locations


Registered Linux User #439761

Offline

#14 2007-03-07 22:33:14

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

SleepingGiant08 wrote:

paste your PKGBUILD, because the one I posted works for me and we have the same locations

# Contributor: Nadav Vinik <nadavvin at gmail.com>
pkgname=php-gtk
pkgver=2.0.0alpha
pkgrel=1
pkgdesc="GTK+ binding to PHP"
depends=(php gtk)
source=(http://gtk.php.net/distributions/php-gtk-2.0.0alpha.tar.gz)
url="http://gtk.php.net"

build() {
        cd $startdir/src/$pkgname-$pkgver
        ./buildconf --with-phpize=/usr/bin/phpize
        ./configure --prefix=/usr/bin --enable-sourceview
        --with-php-config=/usr/bin/php-config
        make || return 1
        make prefix=$startdir/pkg/usr install
}

It should be same as your.

I edit my previous message.

Last edited by nadavvin (2007-03-07 22:34:36)

Offline

#15 2007-03-07 22:40:41

SleepingGiant08
Member
From: Ellicott City, MD USA
Registered: 2007-01-10
Posts: 124

Re: Problem to create a package the download of the source faild

nadavvin wrote:

I copy your edit post and still I get:

configure: error: PHP-GTK 2.x requires GLib 2.6.0 or higher
./PKGBUILD: line 14: --with-php-config=/usr/bin/php-config: No such file or directory
make: *** No targets specified and no makefile found.  Stop.
==> ERROR: Build Failed.  Aborting...
[root@myhost tmp]# ls -l /usr/bin/php-config 
-rwxr-xr-x 1 root root 1265 2007-02-13 19:55 /usr/bin/php-config

What is the problem?

What version for GLib do you have? Try updating GLib like it says

I guess you can try reinstalling (pacman -R php, pacman -S php)  PHP, your error is weird. It should work


Registered Linux User #439761

Offline

#16 2007-03-07 23:09:06

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

# p -S glib
:: glib-1.2.10-6: is up to date.  Upgrade anyway? [Y/n] 

# php --version
PHP 5.2.1 (cli) (built: Feb 13 2007 09:54:41)

Last edited by nadavvin (2007-03-07 23:14:40)

Offline

#17 2007-03-07 23:22:43

SleepingGiant08
Member
From: Ellicott City, MD USA
Registered: 2007-01-10
Posts: 124

Re: Problem to create a package the download of the source faild

nadavvin wrote:
# p -S glib
:: glib-1.2.10-6: is up to date.  Upgrade anyway? [Y/n] 

# php --version
PHP 5.2.1 (cli) (built: Feb 13 2007 09:54:41)

same here... I don't know why it is not building on your system, but it is working for me. I will try to find out some more info...sorry I couldn't be of anymore help

Julian D


Registered Linux User #439761

Offline

#18 2007-03-07 23:22:43

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

I reinstall PHP and still I get the same error.

# p -Sy php
:: Synchronizing package databases... 
 current                  [################] 100%      72K    31.1K/s  00:00:02
 extra                    [################] 100%     277K    81.8K/s  00:00:03
 community                [################] 100%     174K    78.1K/s  00:00:02
:: php-5.2.1-1: is up to date.  Upgrade anyway? [Y/n] y

Targets: php-5.2.1-1

Total Package Size:   6.9 MB

Proceed with upgrade? [Y/n] y

checking package integrity... done.
loading package data... done.
checking for file conflicts... done.
upgrading php... done.
==>
==>  PHP has been built with some optional modules. 
==>  To enable these modules, uncomment the modules from php.ini
==>
==>  The optional modules included in php require extra packages 
==>  to be installed.
==>
==>  - mysql  : libmysqlclient
==>  - pgsql  : postgresql-libs
==>  - ldap   : libldap
==>  - sqlite : sqlite3
==>  - odbc   : unixodbc
==>  - snmp   : net-snmp
==>  - mcrypt : mcrypt 

checking for pkg-config... no
checking for GLIB - version >= 2.6.0... no
*** A new enough version of pkg-config was not found.
*** See http://www.freedesktop.org/software/pkgconfig/
configure: error: PHP-GTK 2.x requires GLib 2.6.0 or higher
./PKGBUILD: line 14: --with-php-config=/usr/bin/php-config: No such file or directory
make: *** No targets specified and no makefile found.  Stop.
==> ERROR: Build Failed.  Aborting...
checking for GLIB - version >= 2.6.0... no

Why no?

Offline

#19 2007-03-07 23:25:31

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

same here... I don't know why it is not building on your system, but it is working for me. I will try to find out some more info...sorry I couldn't be of anymore help

Julian D

thanks for your help.

Offline

#20 2007-03-07 23:29:03

SleepingGiant08
Member
From: Ellicott City, MD USA
Registered: 2007-01-10
Posts: 124

Re: Problem to create a package the download of the source faild

stupid question: did you

pacman -R php

then

pacman -S php

Output all of the messages

makepkg > error

and then paste it here, please


Registered Linux User #439761

Offline

#21 2007-03-08 07:28:44

Snowman
Developer/Forum Fellow
From: Montreal, Canada
Registered: 2004-08-20
Posts: 5,212

Re: Problem to create a package the download of the source faild

Install pkgconfig and add it as a makedepends. That should fix the build problem.

In the configure line, change --prefix=/usr/bin to --prefix=/usr
The PKGBUILD is also missing an arch, licence and md5sums fields.

Offline

#22 2007-03-08 08:52:02

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

Snowman wrote:

Install pkgconfig and add it as a makedepends. That should fix the build problem.

In the configure line, change --prefix=/usr/bin to --prefix=/usr
The PKGBUILD is also missing an arch, licence and md5sums fields.

thanks it work smile

I found a list of dependencies here:
http://www.kksou.com/php-gtk2/articles/ … -linux.php

# Contributor: Nadav Vinik <nadavvin at gmail.com>
pkgname=php-gtk
pkgver=2.0.0alpha
pkgrel=1
pkgdesc="GTK+ binding to PHP"
depends=('php>5.1.6' 'gtk' 'glib>2.6.0' 'libpng>1.2.8' 'freetype>2.2.1' 'fontconfig>2.4.0' 'cairo>1.2.4' 'pango>1.14.7' 'atk>1.9.1' 'libgnomeprint>2.12.1' 'gtksourceview>1.6.0' 'pkgconfig>0.21')
source=(http://gtk.php.net/distributions/php-gtk-2.0.0alpha.tar.gz)
url="http://gtk.php.net"

build() {
        cd $startdir/src/$pkgname-$pkgver
        ./buildconf --with-phpize=/usr/bin/phpize
        ./configure --prefix=/usr --enable-sourceview
        --with-php-config=/usr/bin/php-config
        make || return 1
        make prefix=$startdir/pkg/usr install
}

But I get:

==> Making package: php-gtk 2.0.0alpha-1 (Thu Mar  8 10:45:27 IST 2007)
==> Checking Runtime Dependencies...
==> Missing Dependencies:
==> 
requires: php>5.1.6 
requires: glib>2.6.0 
requires: libpng>1.2.8 
requires: freetype>2.2.1 
requires: fontconfig>2.4.0 
requires: cairo>1.2.4 
requires: pango>1.14.7 
requires: atk>1.9.1 
requires: libgnomeprint>2.12.1 
requires: gtksourceview>1.6.0 
requires: pkgconfig>0.21 
==>

I follow this explanation:

* depends: This should contain an array of package names that need to be installed before this program can be run, separated by spaces. The names can optionally be enclosed in single quotes (apostrophes) to prevent possible shell quoting problems, and the array should be enclosed in round brackets. Sometimes a program requires a minimum version of a dependency; In that case, you might want to use the mathematical "larger or equal than" operator, and enclose the whole construct in quotes. Here's an example to add a dependency on the glibc package, and the slang library of at least version 1.8.0: depends('glibc' 'slang>1.8.0')

From here

What is the problem?

Does GTK+ is part of the gtk package?
I didn't found package of GTK+.


Another problem.

Although, it successfully comple and build, The tar.gz file contain only two files FILELIST and PKGINFO

What is the problem?

Last edited by nadavvin (2007-03-08 09:13:49)

Offline

#23 2007-03-08 17:34:33

Snowman
Developer/Forum Fellow
From: Montreal, Canada
Registered: 2004-08-20
Posts: 5,212

Re: Problem to create a package the download of the source faild

in the depends line, replace > by >=
The wiki has to be updated. Also, usually it is assume the user keep their system uptodate so the version numbers are not used for the dependencies.

Are you building as root? Probably the files were installed directly in the system. That why you should build as a regular user with fakeroot (pacman -S fakeroot).
Try changing:
make prefix=$startdir/pkg/usr install
to
make DESTDIR=$startdir/pkg install

Offline

#24 2007-03-08 17:56:38

nadavvin
Member
Registered: 2006-11-29
Posts: 105

Re: Problem to create a package the download of the source faild

I success to compile now from normal user but it ignore from the DESTDIR:

cp: cannot create regular file `/usr/lib/php/extensions/no-debug-non-zts-20060613/#INST@26250#': Permission denied
make: *** [install-modules] Error 1
==> ERROR: Build Failed.  Aborting...

Offline

#25 2007-03-08 18:15:09

Snowman
Developer/Forum Fellow
From: Montreal, Canada
Registered: 2004-08-20
Posts: 5,212

Re: Problem to create a package the download of the source faild

The Makefile doesn't use the prefix or DESTDIR variables for the installation location. Check what variable it uses instead. It should be under a
install:
line.
If you can't find it, post the Makefile in the pastebin: http://pastebin.archlinux.org/

Offline

Board footer

Powered by FluxBB