Skip to contentSkip to conversation

New: Build libkms against in-tree xf86drm.h

Bug 26852 [email protected] 1 participant 12 messages Mar 3, 2010 – Mar 7, 2011

lore
Share & tools
lore
#0 lore raw

http://bugs.freedesktop.org/show_bug.cgi?id=26852

Summary: Build libkms against in-tree xf86drm.h
Product: DRI
Version: XOrg CVS
Platform: Other
OS/Version: All
Status: NEW
Severity: normal
Priority: medium
Component: libdrm
AssignedTo: [email protected]
ReportedBy: [email protected]

Created an attachment (id=33703)
--> (http://bugs.freedesktop.org/attachment.cgi?id=33703)
Add include dir to libkms Makefile

libkms includes files which include xf86drm.h, but doesn't include the in-tree xf86drm.h in the library include path. This means it will build against the installed header in /usr/include which is probably not the expected behaviour, or if built in a clean chroot will simply fail to build.

Trivial patch attached to fix.

Signature · 11 lines
Configure bugmail: http://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
--
#1 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

http://bugs.freedesktop.org/show_bug.cgi?id=26852

Sérgio M. B. <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |[email protected]

--- Comment #1 from Sérgio M. B. <[email protected]> 2010-03-02 20:13:53 PST --- The question is, if libkms depends on kernel ? and yes I thinks so . Therefore, if libkms , depends on kernel should use xf86drm.h of /usr/include. In this point of view, libkms should know deal with different kernels or even warn if kernel version is not good.

"built in a clean chroot will simply fail to build" , I think that solves install kernel-sources first .

Note: this is my opinion, may not be write.

Signature · 14 lines
Configure bugmail: http://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
--
_______________________________________________
Dri-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dri-devel
#2 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

http://bugs.freedesktop.org/show_bug.cgi?id=26852

--- Comment #2 from Michel Dänzer <[email protected]> 2010-03-03 03:15:54 PST --- (In reply to comment #1)

Quoted 4 lines

The question is, if libkms depends on kernel ? and yes I thinks so . Therefore, if libkms , depends on kernel should use xf86drm.h of /usr/include. In this point of view, libkms should know deal with different kernels or even warn if kernel version is not good.

It needs to deal with that at runtime, not build time.

Signature · 14 lines
Configure bugmail: http://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
--
_______________________________________________
Dri-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dri-devel
#3 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=26852

--- Comment #3 from Christopher James Halse Rogers <[email protected]> 2010-05-25 23:35:04 PDT --- So, until there's an actual kernel incompatibility introduced for which runtime detection in libkms is necessary, is there any reason not to apply this patch?

Building against the headers shipped in the source alongside it makes much more sense to me.

Signature · 3 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
#4 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=26852

--- Comment #4 from Julien Cristau <[email protected]> 2010-06-10 14:09:20 PDT --- the headers part was fixed in ae57dcf6e063860200b7949d5e2365e80ac4aea7, but libdrm is still missing from libkms_la_LIBADD.

Signature · 3 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
#5 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=26852

--- Comment #5 from Sérgio M. B. <[email protected]> 2010-06-15 21:12:52 PDT --- What I'm try to say is, I think the ./configure of libdrm, should check what kernel version we have on system and require a version of kernel bigger than a number which libdrm, we are compiling, works.

Is not logic, build libdrm-2.4.21 with a kernel <= 2.6.26 , I think. So libdrm should avoid those situations.

Signature · 7 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
#6 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=26852

Julien Cristau <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |[email protected]

--- Comment #6 from Julien Cristau <[email protected]> 2010-10-11 13:32:58 PDT --- *** Bug 30782 has been marked as a duplicate of this bug. ***

Signature · 3 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
#7 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=26852

Cyril Brulebois <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |[email protected]

--- Comment #7 from Cyril Brulebois <[email protected]> 2011-03-05 10:10:11 PST --- Ping? As described in the initial report, there's no reason to prefer system headers over those in the same source… I don't understand Sérgio's objection (I fail to see what's illogical).

Signature · 7 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
#8 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=26852

--- Comment #8 from Sérgio M. B. <[email protected]> 2011-03-05 17:28:01 PST --- (In reply to comment #7)

Quoted 3 lines

Ping? As described in the initial report, there's no reason to prefer system headers over those in the same source… I don't understand Sérgio's objection (I fail to see what's illogical).

The illogical is, without that depending on kernel, you may try compile very new libdrm with a older kernel.
libdrm-2.4.21 needs kms on kernel but kernel <= 2.6.26 don't have it.

my 2 cents

Signature · 7 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
#9 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=26852

Matt Turner <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |[email protected]

--- Comment #9 from Matt Turner <[email protected]> 2011-03-05 18:07:50 PST --- (In reply to comment #8)

Quoted 10 lines

(In reply to comment #7)

Quoted 3 lines

Ping? As described in the initial report, there's no reason to prefer system headers over those in the same source… I don't understand Sérgio's objection (I fail to see what's illogical).

The illogical is, without that depending on kernel, you may try compile very new libdrm with a older kernel.
libdrm-2.4.21 needs kms on kernel but kernel <= 2.6.26 don't have it.

my 2 cents

I think you're failing to understand the issue.

xf86drm.h is provided by libdrm. libkms (which is part of libdrm) uses xf86drm.h, but the Makefile searches in /usr/include instead of the $(top_src) directory, where libdrm's xf86drm.h is.

This is like if you have a library that consists of lib.c and lib.h, where lib.c includes lib.h. The Makefile would be incorrect in using lib.h found in /usr/include over the lib.h in the same folder as lib.c.

Signature · 7 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
#10 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=26852

Christopher James Halse Rogers <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED

--- Comment #10 from Christopher James Halse Rogers <[email protected]> 2011-03-06 20:57:41 PST --- This was fixed in ae57dcf6 anyway :)

Signature · 3 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
#11 lore raw

[Bug 26852] Build libkms against in-tree xf86drm.h

In reply to [email protected]

https://bugs.freedesktop.org/show_bug.cgi?id=26852

--- Comment #11 from Julien Cristau <[email protected]> 2011-03-07 10:30:26 PST ---

Quoted 3 lines

--- Comment #10 from Christopher James Halse Rogers <[email protected]> 2011-03-06 20:57:41 PST --- This was fixed in ae57dcf6 anyway :)

only partly, see comment#4.

Signature · 3 lines
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.