Summary: | git version of xserver fails to compile | ||
---|---|---|---|
Product: | xorg | Reporter: | Jos van Wolput <wolput> |
Component: | Server/General | Assignee: | Xorg Project Team <xorg-team> |
Status: | RESOLVED FIXED | QA Contact: | Xorg Project Team <xorg-team> |
Severity: | normal | ||
Priority: | medium | CC: | jeremyhu |
Version: | git | Keywords: | regression |
Hardware: | All | ||
OS: | Linux (All) | ||
Whiteboard: | 2011BRB_Reviewed | ||
i915 platform: | i915 features: |
Description
Jos van Wolput
2011-11-24 18:22:42 UTC
Perhaps size_t is not defined... #ifndef HAVE_STRNDUP extern _X_EXPORT char * strndup(const char *str, size_t n); #endif Does adding this near the top of include/os.h fix your build failure: #include <stdlib.h> (In reply to comment #1) > Does adding this near the top of include/os.h fix your build failure: > > #include <stdlib.h> Yes, it does fix the build failure. Thanks! (In reply to comment #1) > Perhaps size_t is not defined... > #ifndef HAVE_STRNDUP > extern _X_EXPORT char * strndup(const char *str, size_t n); > #endif > > Does adding this near the top of include/os.h fix your build failure: > > #include <stdlib.h> Unfortunately patching /usr/include/xorg/os.h does introduce a build error in building git mesa: --- In file included from /usr/include/xorg/misc.h:109:0, from /usr/include/xorg/xf86str.h:37, from /usr/include/xorg/xf86.h:44, from xorg_tracker.h:41, from xorg_exa.h:4, from xorg_composite.h:4, from xorg_composite.c:1: /usr/include/xorg/os.h:498:25: error: expected identifier or ‘(’ before ‘__extension__’ In file included from /usr/include/xorg/randrstr.h:39:0, from /usr/include/xorg/xf86Crtc.h:27, from xorg_tracker.h:42, from xorg_exa.h:4, from xorg_composite.h:4, from xorg_composite.c:1: /usr/include/xorg/os.h:48:25: error: expected identifier or ‘(’ before ‘__extension__’ make[4]: *** [xorg_composite.o] Error 1 make[4]: Leaving directory `/home/jos/src/xorg/git-master/mesa/src/gallium/state_trackers/xorg' make[3]: *** [subdirs] Error 1 make[3]: Leaving directory `/home/jos/src/xorg/git-master/mesa/src/gallium/state_trackers' make[2]: *** [default] Error 1 make[2]: Leaving directory `/home/jos/src/xorg/git-master/mesa/src/gallium' make[1]: *** [subdirs] Error 1 --- Fixed, no more build failures since latest git version! (In reply to comment #4) > Fixed, no more build failures since latest git version! what is the fix ? I getting the same problem in fedora rawhide The "fix" is to grab the latest sources ... since the latest version builds, I don't want to spend time diving into exactly when your bug was fixed. but still present in xorg-x11-server-1.12.0-1.fc17 . the fix is very simple since is add #include <stdlib.h> before call os.h just FYI. I got this issue also in i386 Sorry for spamming , but I was wrong or something went in my tests , so my lasts comments couldn't be correct. I'm trying compile VirtualBox on Fedora rawhide . and I got: /usr/include/xorg/os.h:497:55: error: expected identifier or ‘(’ before ‘__extension__’ which is also related with #ifndef HAVE_STRNDUP extern _X_EXPORT char * strndup(const char *str, size_t n); #endif (In reply to comment #9) > I'm trying compile VirtualBox on Fedora rawhide . That's not this bug - you're adding comments to an already fixed bug about the X server itself not building, and since it's marked resolved and on a different topic, none of the X developers will be doing anything more with it. Since you have a different problem compiling a different package, you should file a bug in the bug tracker for that package, which is probably on virtualbox.org. (In reply to comment #1) > Perhaps size_t is not defined... > #ifndef HAVE_STRNDUP > extern _X_EXPORT char * strndup(const char *str, size_t n); > #endif > > Does adding this near the top of include/os.h fix your build failure: > > #include <stdlib.h> on bug #47971, my conclusion is, HAVE_STRNDUP should be defined |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.