Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

php-vips 1.0.4 errors out #31

Closed
mnglkhn opened this issue Feb 8, 2017 · 14 comments
Closed

php-vips 1.0.4 errors out #31

mnglkhn opened this issue Feb 8, 2017 · 14 comments

Comments

@mnglkhn
Copy link

mnglkhn commented Feb 8, 2017

Hi,

I have installed vips 8.4 and when I try to install php-vips 1.0.4 it dies out with this message:

"configure: error: you need at least vips 8.2 for this module "

@jcupitt
Copy link
Member

jcupitt commented Feb 8, 2017

Hello, that's asking about the libvips version. What version of libvips do you have installed?

I'll try to improve the wording.

jcupitt added a commit to libvips/php-vips-ext that referenced this issue Feb 8, 2017
@mnglkhn
Copy link
Author

mnglkhn commented Feb 8, 2017

I have libvips in /usr/local/lib/libvips.so, along with libvips.la and libvips.a
I assume it was installed with vips 8.4 since I have not manually installed it.

I should mention that I am on a CentOS 6 box.

@jcupitt
Copy link
Member

jcupitt commented Feb 8, 2017

It sounds like you are missing the headers and the .pc file. Do you have /usr/local/include/vips?

@mnglkhn
Copy link
Author

mnglkhn commented Feb 8, 2017

I just checked and the dir with all header files is there.

@jcupitt
Copy link
Member

jcupitt commented Feb 8, 2017

Then maybe you've not set PKG_CONFIG_PATH? This is the environment variable used to find .pc files, and .pc files are the things used to find headers.

Check you have vips.pc in /usr/local/lib/pkgconfig, check that that directory is on your config path, then try:

$ pkg-config vips --modversion
8.5.0

To verify that the headers can be found.

@jcupitt jcupitt closed this as completed Feb 8, 2017
@jcupitt jcupitt reopened this Feb 8, 2017
@jcupitt
Copy link
Member

jcupitt commented Feb 8, 2017

Oops, didn't mean to close.

@mnglkhn
Copy link
Author

mnglkhn commented Feb 8, 2017

vips.pc is listed in /usr/local/lib/pkgconfig
along with vips-cpp.pc and vipsCC.pc

pkg-config vips --modversion
does not produce an output

@jcupitt
Copy link
Member

jcupitt commented Feb 8, 2017

OK, so you need to set PKG_CONFIG_PATH.

$ export PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH"

You could add that to your .bashrc, it's probably useful elsewhere.

@mnglkhn
Copy link
Author

mnglkhn commented Feb 8, 2017

that did it!

super thanks!

@jcupitt
Copy link
Member

jcupitt commented Feb 8, 2017

Great!

@jcupitt jcupitt closed this as completed Feb 8, 2017
@kleisauke
Copy link
Member

FYI: Currently libvips isn't in any Centos repository. There is package request to get it into the EPEL, see: https://bugzilla.redhat.com/1189137

If you're running Centos >= 7 then there's an easier way to install libvips (v8.4.4) and the PHP vips (v1.0.4) extension (the Remi repository provides a easy way to install it).

# Install the EPEL repository configuration package:
yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm

# Install the Remi repository configuration package:
yum install http://rpms.remirepo.net/enterprise/remi-release-7.rpm

# Install the yum-utils package (for the yum-config-manager command):
yum install yum-utils

# Command to enable the repository (PHP 7.1.1, for PHP 7.0.15 use: remi-php70):
yum-config-manager --enable remi-php71

# Install libvips and the PHP vips extension:
yum install php-pecl-vips

@mnglkhn
Copy link
Author

mnglkhn commented Feb 8, 2017

@kleisauke : Super nice this install guide for CentOS!

My approach was to:


A. Install VIPS from source

wget http://www.vips.ecs.soton.ac.uk/supported/current/vips-8.4.5.tar.gz /tmp/vips-8.4.5.tar.gz
cd /tmp/
tar -xzvf vips-8.4.5.tar.gz
cd vips-8.4.5
./configure
make && make install

vi ~/.bashrc # to add
export PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH"
source ~/.bashrc


B. Install PHP-VIPS-EXT

pecl install vips


C. Install PHP-VIPS

composer require jcupitt/vips

NOTE:

In order to have PECL you need to install PEAR.
Obviously, first try to install pear using your package manager.

Otherwise:

curl -O https://pear.php.net/go-pear.phar
sudo php -d detect_unicode=0 go-pear.phar

@airqb
Copy link

airqb commented Nov 27, 2019

Hello there, I am trying to use VIPS in golang in fact it was working fine but not anymore after update golang, I try many ways but still getting this message

GOROOT=/Users/qbgrow/go/go1.13.4 #gosetup
GOPATH=/Users/qbgrow/go #gosetup
/Users/qbgrow/go/go1.13.4/bin/go build -o /private/var/folders/gt/y155t_6j50sf5f55b1qqvh8r0000gn/T/___go_build_ApiServer_go /Users/qbgrow/go/src/api-server/ApiServer.go #gosetup
# pkg-config --cflags  -- vips vips vips vips vips vips vips vips vips
Package libffi was not found in the pkg-config search path.
Perhaps you should add the directory containing `libffi.pc'
to the PKG_CONFIG_PATH environment variable
Package 'libffi', required by 'gobject-2.0', not found
pkg-config: exit status 1

@jcupitt
Copy link
Member

jcupitt commented Nov 27, 2019

Sorry, you'd need to ask the project maintaining the go binding.

@libvips libvips locked as resolved and limited conversation to collaborators Nov 27, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants