test: remove hack for private header inclusion

Message ID 20210624115319.15809-1-david.marchand@redhat.com (mailing list archive)
State Accepted, archived
Delegated to: David Marchand
Headers
Series test: remove hack for private header inclusion |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation fail Compilation issues
ci/iol-intel-Functional success Functional Testing PASS
ci/github-robot success github build: passed
ci/iol-abi-testing success Testing PASS
ci/iol-testing success Testing PASS
ci/intel-Testing success Testing PASS

Commit Message

David Marchand June 24, 2021, 11:53 a.m. UTC
  This hack was needed with the make build system.
With meson, any private header from a library is visible as long as a
dependency to this library is expressed.

Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 app/test/test_eal_fs.c         | 3 +--
 app/test/test_memzone.c        | 3 ++-
 app/test/test_telemetry_json.c | 3 ++-
 3 files changed, 5 insertions(+), 4 deletions(-)
  

Comments

Bruce Richardson June 24, 2021, 12:09 p.m. UTC | #1
On Thu, Jun 24, 2021 at 01:53:19PM +0200, David Marchand wrote:
> This hack was needed with the make build system.
> With meson, any private header from a library is visible as long as a
> dependency to this library is expressed.
> 
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> ---
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
  
Tyler Retzlaff June 24, 2021, 4:07 p.m. UTC | #2
On Thu, Jun 24, 2021 at 01:53:19PM +0200, David Marchand wrote:
> This hack was needed with the make build system.
> With meson, any private header from a library is visible as long as a
> dependency to this library is expressed.
> 
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> ---

Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
  
David Marchand July 6, 2021, 2:41 p.m. UTC | #3
On Thu, Jun 24, 2021 at 1:53 PM David Marchand
<david.marchand@redhat.com> wrote:
>
> This hack was needed with the make build system.
> With meson, any private header from a library is visible as long as a
> dependency to this library is expressed.
>
> Signed-off-by: David Marchand <david.marchand@redhat.com>

Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>

Applied.
  

Patch

diff --git a/app/test/test_eal_fs.c b/app/test/test_eal_fs.c
index bb93b82a43..39ac6961b3 100644
--- a/app/test/test_eal_fs.c
+++ b/app/test/test_eal_fs.c
@@ -8,8 +8,7 @@ 
 #include <string.h>
 #include <errno.h>
 
-/* eal_filesystem.h is not a public header file, so use relative path */
-#include "../../lib/eal/common/eal_filesystem.h"
+#include "eal_filesystem.h"
 
 static int
 test_parse_sysfs_value(void)
diff --git a/app/test/test_memzone.c b/app/test/test_memzone.c
index 03a9d1d3bb..27b8b52fcd 100644
--- a/app/test/test_memzone.c
+++ b/app/test/test_memzone.c
@@ -18,7 +18,8 @@ 
 #include <rte_string_fns.h>
 #include <rte_errno.h>
 #include <rte_malloc.h>
-#include "../../lib/eal/common/malloc_elem.h"
+
+#include "malloc_elem.h"
 
 #include "test.h"
 
diff --git a/app/test/test_telemetry_json.c b/app/test/test_telemetry_json.c
index 3171ab12ec..790181d316 100644
--- a/app/test/test_telemetry_json.c
+++ b/app/test/test_telemetry_json.c
@@ -4,7 +4,8 @@ 
 
 #include <string.h>
 
-#include "../../lib/telemetry/telemetry_json.h"
+#include "telemetry_json.h"
+
 #include "test.h"
 
 static int