libxcb build fails on ubuntu 14.04

440 views
Skip to first unread message

John Wohlbier

unread,
May 11, 2016, 11:12:25 AM5/11/16
to Spack
Towards building openspeedshop I am tripping on libxcb. Ubuntu 14.04, gcc 4.8.4


Failure of libxcb:

checking if /home/wohlbier/devel/packages/spack/lib/spack/env/gcc/gcc -std=gnu99 supports -Werror=attributes... yes
Package xorg-macros was not found in the pkg-config search path.
Perhaps you should add the directory containing `xorg-macros.pc'
to the PKG_CONFIG_PATH environment variable
No package 'xorg-macros' found
checking whether make supports nested variables... (cached) yes
checking whether to build developer documentation... yes
checking for doxygen... no
configure: WARNING: doxygen not found - documentation targets will be skipped
configure: WARNING: dot not found - doxygen targets will be skipped
checking for CHECK... no
checking for XCBPROTO... yes
checking for NEEDED... no
configure: error: Package requirements (pthread-stubs xau >= 0.99.2) were not met:

No package 'pthread-stubs' found
No package 'xau' found

Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.

Alternatively, you may set the environment variables NEEDED_CFLAGS
and NEEDED_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.


In spack/var/spack/repos/builtin/packages/libxcb/package.py I see

    # depends_on('pthread')    # Ubuntu: apt-get install libpthread-stubs0-dev
    # depends_on('xau')        # Ubuntu: apt-get install libxau-dev


and indeed:
wohlbier@wohlbier-VirtualBox-14:~/devel/packages$ dpkg -s libpthread-stubs0-dev
Package: libpthread-stubs0-dev
Status: install ok installed
Priority: optional
Section: libdevel
Installed-Size: 40
Maintainer: Ubuntu Developers <ubuntu-dev...@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libpthread-stubs
Version: 0.3-4

wohlbier@wohlbier-VirtualBox-14:~/devel/packages$ dpkg -s libxau-dev
Package: libxau-dev
Status: install ok installed
Priority: optional
Section: libdevel
Installed-Size: 81
Maintainer: Ubuntu Developers <ubuntu-dev...@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libxau
Version: 1:1.0.8-1
Depends: libxau6 (= 1:1.0.8-1), x11proto-core-dev


Ideas?

Thanks.
jgw

John Wohlbier

unread,
May 11, 2016, 12:31:46 PM5/11/16
to Spack
I worked around it by patching configure.

wohlbier@wohlbier-VirtualBox-14:~/devel/packages/spack$ git diff
diff --git a/var/spack/repos/builtin/packages/libxcb/package.py b/var/spack/repo
index b2543be..4582375 100644
--- a/var/spack/repos/builtin/packages/libxcb/package.py
+++ b/var/spack/repos/builtin/packages/libxcb/package.py
@@ -20,6 +20,7 @@ class Libxcb(Package):
 
     def patch(self):
         filter_file('typedef struct xcb_auth_info_t {', 'typedef struct {', 'sr
+        filter_file('NEEDED="pthread-stubs xau >= 0.99.2"','NEEDED_CFLAGS=" "; 
 
 
     def install(self, spec, prefix):

Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libpthread-stubs
Version: 0.3-4

wohlbier@wohlbier-VirtualBox-14:~/devel/packages$ dpkg -s libxau-dev
Package: libxau-dev
Status: install ok installed
Priority: optional
Section: libdevel
Installed-Size: 81
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libxau
Version: 1:1.0.8-1
Depends: libxau6 (= 1:1.0.8-1), x11proto-core-dev


Ideas?

Thanks.
jgw

Todd Gamblin

unread,
May 11, 2016, 12:36:22 PM5/11/16
to John Wohlbier, Spack
Hi John:

I think this is an artifact of the X11 stack in Spack being a little sparse.  Spack should probably have pthread-stubs, xau, and some others in the package archives. 

DJ: were you going to look into this?

-Todd

--
You received this message because you are subscribed to the Google Groups "Spack" group.
To unsubscribe from this group and stop receiving emails from it, send an email to spack+un...@googlegroups.com.
To post to this group, send email to sp...@googlegroups.com.
Visit this group at https://groups.google.com/group/spack.
For more options, visit https://groups.google.com/d/optout.

John Wohlbier

unread,
May 11, 2016, 1:00:00 PM5/11/16
to Spack
a diff that actually works:


wohlbier@wohlbier-VirtualBox-14:~/devel/packages/spack$ git diff
diff --git a/var/spack/repos/builtin/packages/libxcb/package.py b/var/spack/repos/builtin/packages/libxcb/package.py
index b2543be..e4e53ec 100644
--- a/var/spack/repos/builtin/packages/libxcb/package.py
+++ b/var/spack/repos/builtin/packages/libxcb/package.py
@@ -20,6 +20,7 @@ class Libxcb(Package):
 
     def patch(self):
         filter_file('typedef struct xcb_auth_info_t {', 'typedef struct {', 'src/xcb.h')
+        filter_file('NEEDED="pthread-stubs xau >= 0.99.2"','NEEDED_CFLAGS=" "; NEEDED_LIBS="-lXau"','configure')

Dhanannjay (DJ) Deo

unread,
May 11, 2016, 6:32:36 PM5/11/16
to John Wohlbier, Spack
Hello Todd,

I adding few dependencies libpthread-stubs,  libXau,  xproto that build libxcb on linux in merge request for qt5.6.0. That pr also includes few more xcb-utils-* that are needed for qt. 


Shall I separate the commits related with libxcb into another merge request ? that will be easy to review until qt gets finalized.

Thank you,

:) D'jay 

Maintainer: Ubuntu Developers <ubuntu-dev...@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libpthread-stubs
Version: 0.3-4

wohlbier@wohlbier-VirtualBox-14:~/devel/packages$ dpkg -s libxau-dev
Package: libxau-dev
Status: install ok installed
Priority: optional
Section: libdevel
Installed-Size: 81
Maintainer: Ubuntu Developers <ubuntu-dev...@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libxau
Version: 1:1.0.8-1
Depends: libxau6 (= 1:1.0.8-1), x11proto-core-dev


Ideas?

Thanks.
jgw

--
You received this message because you are subscribed to the Google Groups "Spack" group.
To unsubscribe from this group and stop receiving emails from it, send an email to spack+un...@googlegroups.com.
To post to this group, send email to sp...@googlegroups.com.
Visit this group at https://groups.google.com/group/spack.
For more options, visit https://groups.google.com/d/optout.



--
Dhanannjay (D'jay) Deo, Ph.D.
Scientific and Medical Visualization
Kitware Inc.
www.kitware.com
Phone : (518)-836-2196

Todd Gamblin

unread,
May 11, 2016, 8:12:41 PM5/11/16
to Dhanannjay (DJ) Deo, John Wohlbier, Spack
DJ:

I think we can wait until the Qt merge takes place.  If John wants to try that stuff out he can subscribe to your pull request in the meantime.  It sounds like the Qt stuff is almost ready to go, aside from Denis's review points. Is that correct?

-Todd

Denis Davydov

unread,
May 12, 2016, 5:01:40 AM5/12/16
to Spack, dhanann...@kitware.com, johnwo...@gmail.com
Hi all,

On Thursday, May 12, 2016 at 2:12:41 AM UTC+2, Todd Gamblin wrote:
subscribe to your pull request in the meantime.  It sounds like the Qt stuff is almost ready to go, aside from Denis's review points. Is that correct?

Most of them are addressed already, but there are a couple left.
I look forward to having a working Qt in Spack.

Regards,
Denis. 

John Wohlbier

unread,
May 12, 2016, 12:41:47 PM5/12/16
to Jim Galarowicz, Spack
Great. Glad it could help someone else.

Somebody asked me to issue a PR for it, but it doesn't seem like patching the configure file is a very robust fix, and there are people working on putting the required libraries into spack, so I passed.

I did run into another issue building openspeedshop, and that is libmonitor did not exist at the URL given in package.py. I fixed that and issued a PR for it. I finally have a oss build and am running an mpi trace ;)

jgw

On Thu, May 12, 2016 at 10:30 AM, Jim Galarowicz <j...@krellinst.org> wrote:
Hi John,

I just ran into the same issue on Fedora.   Your patch fixed the issue on Fedora.

Thanks!

Jim G
Maintainer: Ubuntu Developers <ubuntu-dev...@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libpthread-stubs
Version: 0.3-4

wohlbier@wohlbier-VirtualBox-14:~/devel/packages$ dpkg -s libxau-dev
Package: libxau-dev
Status: install ok installed
Priority: optional
Section: libdevel
Installed-Size: 81
Maintainer: Ubuntu Developers <ubuntu-dev...@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libxau
Version: 1:1.0.8-1
Depends: libxau6 (= 1:1.0.8-1), x11proto-core-dev


Ideas?

Thanks.
jgw
--

Jim Galarowicz

unread,
May 12, 2016, 12:42:31 PM5/12/16
to John Wohlbier, Spack
Hi John,

I just ran into the same issue on Fedora.   Your patch fixed the issue on Fedora.

Thanks!

Jim G


On 05/11/2016 10:00 AM, John Wohlbier wrote:
--

Jim Galarowicz

unread,
May 12, 2016, 12:58:48 PM5/12/16
to John Wohlbier, Spack
Hi John,

I didn't run into the libmonitor issue because I already had it installed.   I wonder if our patches will still apply cleanly.
I will uninstall and test this.   libmonitor maintainers have not accepted our patches, so we have to drag them along.

Thanks,
Jim G

John Wohlbier

unread,
May 12, 2016, 1:45:16 PM5/12/16
to Jim Galarowicz, Spack
I believe the patches applied cleanly. I set the git hash to correspond to the 20130218 version here

Elizabeth F

unread,
May 12, 2016, 5:03:26 PM5/12/16
to John Wohlbier, Jim Galarowicz, Spack
John,

I still recommend submitting the patch, especially now that others have had good experience with it too.  In the package.py file, just make the patch specific to the exact version of libxcb that you downloaded.  That tarball is checksummed, so we know it will never change.  Your patch won't fix futures versions of libxcb, which might have a different configure script.  But it will make life easier for anyone building Qt today, which I think is a worthy contribution.

-- Elizabeth

John Wohlbier

unread,
May 12, 2016, 6:21:30 PM5/12/16
to Spack
Ok, I can do it. I won't know what the error will look like if an Ubuntu or Fedora user does not actually have libXau installed, and don't really have time to try out such a scenario.
jgw


On Wednesday, May 11, 2016 at 9:12:25 AM UTC-6, John Wohlbier wrote:
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libpthread-stubs
Version: 0.3-4

wohlbier@wohlbier-VirtualBox-14:~/devel/packages$ dpkg -s libxau-dev
Package: libxau-dev
Status: install ok installed
Priority: optional
Section: libdevel
Installed-Size: 81
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: libxau
Version: 1:1.0.8-1
Depends: libxau6 (= 1:1.0.8-1), x11proto-core-dev


Ideas?

Thanks.
jgw
Reply all
Reply to author
Forward
0 new messages