开发者

How to setup libsoup for ubuntu

I am trying to install libsoup for my ubuntu environment:

checking for LIBSOUP... configure: error: Package requirements (libsoup-2.4 >= 2.28.2) were not met:

No package 'libsoup-2.4' found

I tried

$ sudo apt-get install libsoup2.4-dev

and now it said:

checking for LIBSOUP... configure开发者_运维技巧: error: Package requirements (libsoup-2.4 >= 2.28.2) were not met:

Requested 'libsoup-2.4 >= 2.28.2' but version of libsoup is 2.4.1

Thanks for any suggestion in how to fix this problem.


I know this is old but for anyone stumbling across this post I fixed this common issue after the following debugging:


IMPORTANT: The required webkit version may have changed since the OP asked this question, so check the file ~/src/Webkit/configure.ac and search for LIBSOUP_REQUIRED_VERSION. If a version other than 2.28.2 is listed, remember to use the correct version in all the commands.

Also at the time of writing, libsoup-2.4 was the latest stable libsoup release. if this is not still the case you will need to replace all mentions of libsoup-2.4 with the correct package name.

Finally, these steps only enabled me to get past the libsoup not found issue. I'm still unable to build webkit during the make phase.


The trick is this command: pkg-config --exists --print-errors 'libsoup-2.4 >= 2.28.2'. Basically you need this command to execute without errors (if successful the output will be blank).

  1. run pkg-config --modversion libsoup-2.4 to check the branch of libsoup you are running (mine was 2.38.1)

  2. if the result was not as you expected - run sudo ldconfig and sudo updatedb to ensure your libraries are reporting the latest versions and repeat step 1

  3. if your reported version is lower than webkit requires (check ~/src/Webkit/configure.ac and search for LIBSOUP_REQUIRED_VERSION ), then you may need to download libsoup source, manually compile & add the new path to PKG_CONFIG_PATH using export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:absolute_path_to_libsoup_directory). Your libsoup directory is the one that contains libsoup-2.4.pc.

  4. open up ~/src/Webkit/configure.ac again and search for PKG_CHECK_MODULES([LIBSOUP]. On the line below this it make sure that the first argument for the comparison exactly matches the package name passed in to pkg-config in step 1 (I had to change libsoup to libsoup-2.4)

  5. run the command pkg-config --exists --print-errors 'libsoup-2.4 >= 2.28.2'.

  6. run sudo ./src/Webkit/autogen.sh --prefix=/usr again and hopefully it'll pass


It looks like you need to fix the configure script of the package you are trying to build as it seems to get the test wrong.


You can install a more recent version of libsoup by downloading it and following the steps in http://www.linuxfromscratch.org/blfs/view/svn/basicnet/libsoup.html

To make the long story short:

Make sure you have all dependencies, in my Ubuntu 14.04 I needed to install the following:

sudo apt-get install libsqlite3-dev valac

Then compile libsoup:

sed -i "/seems to be moved/s/^/#/" build-aux/ltmain.sh && ./configure --prefix=/usr --disable-static && make

Install libsoup:

sudo make install

Update the database for mlocate:

sudo updatedb

Make sure the metadata file for pkg-config is the correct one:

locate libsoup-2.4.pc

The output should be in:

/usr/lib/pkgconfig/libsoup-2.4.pc

Final test:

pkg-config --modversion libsoup-2.4
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜