linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] selftests/android/ion: Makefile: fix build error
@ 2018-03-08 14:37 Anders Roxell
  2018-03-08 19:32 ` Laura Abbott
  0 siblings, 1 reply; 4+ messages in thread
From: Anders Roxell @ 2018-03-08 14:37 UTC (permalink / raw)
  To: shuah
  Cc: pintu.ping, labbott, daniel.vetter, linux-kselftest,
	linux-kernel, Anders Roxell

Fails to build iomap_test.c due to missing include

gcc  -I. -I../../../../../drivers/staging/android/uapi/ -Wall -O2 -g
ionmap_test.c ipcsocket.c ionutils.c   -o ionmap_test
ionmap_test.c:12:27: fatal error: linux/dma-buf.h: No such file or
directory
 #include <linux/dma-buf.h>
                           ^
compilation terminated.
<builtin>: recipe for target 'ionmap_test' failed
make[2]: *** [ionmap_test] Error 1

In the current code, we add a new -I ../../../../../usr/include/ to the
INCLUDEDIR variable. Also add ionmap_test to the .gitignore file.

Fixes: ac93f7046a53 ("selftests: ion: Add simple test with the vgem driver")
Signed-off-by: Anders Roxell <anders.roxell@linaro.org>
---
 tools/testing/selftests/android/ion/.gitignore | 1 +
 tools/testing/selftests/android/ion/Makefile   | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/tools/testing/selftests/android/ion/.gitignore b/tools/testing/selftests/android/ion/.gitignore
index 67e6f391b2a9..95e8f4561474 100644
--- a/tools/testing/selftests/android/ion/.gitignore
+++ b/tools/testing/selftests/android/ion/.gitignore
@@ -1,2 +1,3 @@
 ionapp_export
 ionapp_import
+ionmap_test
diff --git a/tools/testing/selftests/android/ion/Makefile b/tools/testing/selftests/android/ion/Makefile
index d23b6d537d8b..e03695287f76 100644
--- a/tools/testing/selftests/android/ion/Makefile
+++ b/tools/testing/selftests/android/ion/Makefile
@@ -1,5 +1,5 @@
 
-INCLUDEDIR := -I. -I../../../../../drivers/staging/android/uapi/
+INCLUDEDIR := -I. -I../../../../../drivers/staging/android/uapi/ -I../../../../../usr/include/
 CFLAGS := $(CFLAGS) $(INCLUDEDIR) -Wall -O2 -g
 
 TEST_GEN_FILES := ionapp_export ionapp_import ionmap_test
-- 
2.11.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] selftests/android/ion: Makefile: fix build error
  2018-03-08 14:37 [PATCH] selftests/android/ion: Makefile: fix build error Anders Roxell
@ 2018-03-08 19:32 ` Laura Abbott
  2018-03-08 23:30   ` Anders Roxell
  0 siblings, 1 reply; 4+ messages in thread
From: Laura Abbott @ 2018-03-08 19:32 UTC (permalink / raw)
  To: Anders Roxell, shuah
  Cc: pintu.ping, daniel.vetter, linux-kselftest, linux-kernel

On 03/08/2018 06:37 AM, Anders Roxell wrote:
> Fails to build iomap_test.c due to missing include
> 
> gcc  -I. -I../../../../../drivers/staging/android/uapi/ -Wall -O2 -g
> ionmap_test.c ipcsocket.c ionutils.c   -o ionmap_test
> ionmap_test.c:12:27: fatal error: linux/dma-buf.h: No such file or
> directory
>   #include <linux/dma-buf.h>
>                             ^
> compilation terminated.
> <builtin>: recipe for target 'ionmap_test' failed
> make[2]: *** [ionmap_test] Error 1
> 
> In the current code, we add a new -I ../../../../../usr/include/ to the
> INCLUDEDIR variable. Also add ionmap_test to the .gitignore file.
> > Fixes: ac93f7046a53 ("selftests: ion: Add simple test with the vgem driver")

Where is this hash from? It's not in Linus' master branch.
Are the /usr/include header properly sanitized, if so that's nice
because there's been debates before about how best to pick up
the sanitized headers. I see that used several other places
around self-tests too. Anyway, you can add

Acked-by: Laura Abbott <labbott@redhat.com>

Thanks,
Laura

> Signed-off-by: Anders Roxell <anders.roxell@linaro.org>
> ---
>   tools/testing/selftests/android/ion/.gitignore | 1 +
>   tools/testing/selftests/android/ion/Makefile   | 2 +-
>   2 files changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/tools/testing/selftests/android/ion/.gitignore b/tools/testing/selftests/android/ion/.gitignore
> index 67e6f391b2a9..95e8f4561474 100644
> --- a/tools/testing/selftests/android/ion/.gitignore
> +++ b/tools/testing/selftests/android/ion/.gitignore
> @@ -1,2 +1,3 @@
>   ionapp_export
>   ionapp_import
> +ionmap_test
> diff --git a/tools/testing/selftests/android/ion/Makefile b/tools/testing/selftests/android/ion/Makefile
> index d23b6d537d8b..e03695287f76 100644
> --- a/tools/testing/selftests/android/ion/Makefile
> +++ b/tools/testing/selftests/android/ion/Makefile
> @@ -1,5 +1,5 @@
>   
> -INCLUDEDIR := -I. -I../../../../../drivers/staging/android/uapi/
> +INCLUDEDIR := -I. -I../../../../../drivers/staging/android/uapi/ -I../../../../../usr/include/
>   CFLAGS := $(CFLAGS) $(INCLUDEDIR) -Wall -O2 -g
>   
>   TEST_GEN_FILES := ionapp_export ionapp_import ionmap_test
> 


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] selftests/android/ion: Makefile: fix build error
  2018-03-08 19:32 ` Laura Abbott
@ 2018-03-08 23:30   ` Anders Roxell
  2018-03-21 16:52     ` Shuah Khan
  0 siblings, 1 reply; 4+ messages in thread
From: Anders Roxell @ 2018-03-08 23:30 UTC (permalink / raw)
  To: Laura Abbott
  Cc: shuah, Pintu Kumar, Daniel Vetter, linux-kselftest,
	Linux Kernel Mailing List

On 8 March 2018 at 20:32, Laura Abbott <labbott@redhat.com> wrote:
> On 03/08/2018 06:37 AM, Anders Roxell wrote:
>>
>> Fails to build iomap_test.c due to missing include
>>
>> gcc  -I. -I../../../../../drivers/staging/android/uapi/ -Wall -O2 -g
>> ionmap_test.c ipcsocket.c ionutils.c   -o ionmap_test
>> ionmap_test.c:12:27: fatal error: linux/dma-buf.h: No such file or
>> directory
>>   #include <linux/dma-buf.h>
>>                             ^
>> compilation terminated.
>> <builtin>: recipe for target 'ionmap_test' failed
>> make[2]: *** [ionmap_test] Error 1
>>
>> In the current code, we add a new -I ../../../../../usr/include/ to the
>> INCLUDEDIR variable. Also add ionmap_test to the .gitignore file.
>> > Fixes: ac93f7046a53 ("selftests: ion: Add simple test with the vgem
>> > driver")
>
>
> Where is this hash from?

In linux-next.

> It's not in Linus' master branch.
> Are the /usr/include header properly sanitized

That my understanding but please correct me if I'm wrong.

Cheers,
Anders

>, if so that's nice
> because there's been debates before about how best to pick up
> the sanitized headers. I see that used several other places
> around self-tests too. Anyway, you can add
>
> Acked-by: Laura Abbott <labbott@redhat.com>
>
> Thanks,
> Laura
>
>
>> Signed-off-by: Anders Roxell <anders.roxell@linaro.org>
>> ---
>>   tools/testing/selftests/android/ion/.gitignore | 1 +
>>   tools/testing/selftests/android/ion/Makefile   | 2 +-
>>   2 files changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/tools/testing/selftests/android/ion/.gitignore
>> b/tools/testing/selftests/android/ion/.gitignore
>> index 67e6f391b2a9..95e8f4561474 100644
>> --- a/tools/testing/selftests/android/ion/.gitignore
>> +++ b/tools/testing/selftests/android/ion/.gitignore
>> @@ -1,2 +1,3 @@
>>   ionapp_export
>>   ionapp_import
>> +ionmap_test
>> diff --git a/tools/testing/selftests/android/ion/Makefile
>> b/tools/testing/selftests/android/ion/Makefile
>> index d23b6d537d8b..e03695287f76 100644
>> --- a/tools/testing/selftests/android/ion/Makefile
>> +++ b/tools/testing/selftests/android/ion/Makefile
>> @@ -1,5 +1,5 @@
>>   -INCLUDEDIR := -I. -I../../../../../drivers/staging/android/uapi/
>> +INCLUDEDIR := -I. -I../../../../../drivers/staging/android/uapi/
>> -I../../../../../usr/include/
>>   CFLAGS := $(CFLAGS) $(INCLUDEDIR) -Wall -O2 -g
>>     TEST_GEN_FILES := ionapp_export ionapp_import ionmap_test
>>
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] selftests/android/ion: Makefile: fix build error
  2018-03-08 23:30   ` Anders Roxell
@ 2018-03-21 16:52     ` Shuah Khan
  0 siblings, 0 replies; 4+ messages in thread
From: Shuah Khan @ 2018-03-21 16:52 UTC (permalink / raw)
  To: Anders Roxell, Laura Abbott
  Cc: Pintu Kumar, Daniel Vetter, linux-kselftest,
	Linux Kernel Mailing List, Shuah Khan, Shuah Khan

On 03/08/2018 04:30 PM, Anders Roxell wrote:
> On 8 March 2018 at 20:32, Laura Abbott <labbott@redhat.com> wrote:
>> On 03/08/2018 06:37 AM, Anders Roxell wrote:
>>>
>>> Fails to build iomap_test.c due to missing include
>>>
>>> gcc  -I. -I../../../../../drivers/staging/android/uapi/ -Wall -O2 -g
>>> ionmap_test.c ipcsocket.c ionutils.c   -o ionmap_test
>>> ionmap_test.c:12:27: fatal error: linux/dma-buf.h: No such file or
>>> directory
>>>   #include <linux/dma-buf.h>
>>>                             ^
>>> compilation terminated.
>>> <builtin>: recipe for target 'ionmap_test' failed
>>> make[2]: *** [ionmap_test] Error 1
>>>
>>> In the current code, we add a new -I ../../../../../usr/include/ to the
>>> INCLUDEDIR variable. Also add ionmap_test to the .gitignore file.
>>>> Fixes: ac93f7046a53 ("selftests: ion: Add simple test with the vgem
>>>> driver")
>>
>>
>> Where is this hash from?
> 
> In linux-next.
> 
>> It's not in Linus' master branch.
>> Are the /usr/include header properly sanitized
> 
> That my understanding but please correct me if I'm wrong.
> 
> Cheers,
> Anders
> 
>> , if so that's nice
>> because there's been debates before about how best to pick up
>> the sanitized headers. I see that used several other places
>> around self-tests too. Anyway, you can add
>>
>> Acked-by: Laura Abbott <labbott@redhat.com>
>>

Thanks. Applied to linux-kselftest next for 4.17-rc1

-- Shuah


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-03-21 16:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-08 14:37 [PATCH] selftests/android/ion: Makefile: fix build error Anders Roxell
2018-03-08 19:32 ` Laura Abbott
2018-03-08 23:30   ` Anders Roxell
2018-03-21 16:52     ` Shuah Khan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).