diff mbox

[PATCHv2] validation: reorder Makefile.am

Message ID 1419862772-23660-1-git-send-email-maxim.uvarov@linaro.org
State New
Headers show

Commit Message

Maxim Uvarov Dec. 29, 2014, 2:19 p.m. UTC
1. Reorder programs in Makefile.am to be in alphabetical order.
2. Put common source to variable.
3. Put source names on separate line to have less merge conflicts.

Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
---
 v2: put scripts to variable list.

 test/validation/Makefile.am | 53 +++++++++++++++++++++++++++++++--------------
 1 file changed, 37 insertions(+), 16 deletions(-)

Comments

Mike Holmes Jan. 15, 2015, 10:15 p.m. UTC | #1
This might make it clearer to users that there is a distinction between
tests and scripts that run tests but the patch no longer applies

On 29 December 2014 at 09:19, Maxim Uvarov <maxim.uvarov@linaro.org> wrote:

> 1. Reorder programs in Makefile.am to be in alphabetical order.
> 2. Put common source to variable.
> 3. Put source names on separate line to have less merge conflicts.
>
> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
> ---
>  v2: put scripts to variable list.
>
>  test/validation/Makefile.am | 53
> +++++++++++++++++++++++++++++++--------------
>  1 file changed, 37 insertions(+), 16 deletions(-)
>
> diff --git a/test/validation/Makefile.am b/test/validation/Makefile.am
> index c0545b7..5a12ac9 100644
> --- a/test/validation/Makefile.am
> +++ b/test/validation/Makefile.am
> @@ -4,26 +4,47 @@ AM_CFLAGS += -I$(srcdir)/common
>  AM_LDFLAGS += -static
>
>  TESTS_ENVIRONMENT = ODP_PLATFORM=${with_platform}
> +#
> +# BINS - list to compile and execute with make check
>

call it EXECUTABLES and drop the comment ?


> +#
> +BINS = odp_buffer      \
> +       odp_crypto      \
> +       odp_init                \
> +       odp_queue       \
> +       odp_schedule    \
> +       odp_shm         \
> +       odp_system
> +#
> +# BINS_COMPILE - list to compile only
>

would a variable called COMPILE_ONLY  be better and drop the comment ?


> +#
> +BINS_COMPILE = odp_pktio
> +#
> +# TSCRIPTS - list of scripts to be executed with make check
> +#
> +TSCRIPTS = odp_pktio_run
>

Why T ?  TEST_SCRIPTS ? If so maybe we know they are tests scripts and just
call them SCRIPTS ?
Can the TSCRIPTS list be generated from the BINS_COMPILE List  ?


>
>  if ODP_CUNIT_ENABLED
> -TESTS = odp_init odp_queue odp_crypto odp_shm odp_schedule odp_pktio_run
> odp_buffer odp_system
> -check_PROGRAMS = ${bin_PROGRAMS}
> -bin_PROGRAMS = odp_init odp_queue odp_crypto odp_shm odp_schedule
> odp_pktio odp_buffer odp_system
> -odp_crypto_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/crypto
> -odp_buffer_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/buffer
> +TESTS = $(BINS) $(TSCRIPTS)
> +bin_PROGRAMS = $(BINS) $(BINS_COMPILE)
>  endif
>
> -dist_odp_init_SOURCES = odp_init.c
> -dist_odp_pktio_SOURCES = odp_pktio.c common/odp_cunit_common.c
> -dist_odp_queue_SOURCES = odp_queue.c common/odp_cunit_common.c
> -dist_odp_crypto_SOURCES = crypto/odp_crypto_test_async_inp.c \
> -                         crypto/odp_crypto_test_sync_inp.c \
> -                         crypto/odp_crypto_test_rng.c \
> -                         odp_crypto.c common/odp_cunit_common.c
> -dist_odp_shm_SOURCES = odp_shm.c common/odp_cunit_common.c
> -dist_odp_schedule_SOURCES = odp_schedule.c common/odp_cunit_common.c
> +check_PROGRAMS = ${bin_PROGRAMS}
> +
> +ODP_CU_COMMON=common/odp_cunit_common.c
> +
> +odp_buffer_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/buffer
>  dist_odp_buffer_SOURCES = buffer/odp_buffer_pool_test.c \
>                           buffer/odp_buffer_test.c \
>                           buffer/odp_packet_test.c \
> -                         odp_buffer.c common/odp_cunit_common.c
> -dist_odp_system_SOURCES = odp_system.c common/odp_cunit_common.c
> +                         odp_buffer.c $(ODP_CU_COMMON)
> +odp_crypto_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/crypto
> +dist_odp_crypto_SOURCES = crypto/odp_crypto_test_async_inp.c \
> +                         crypto/odp_crypto_test_sync_inp.c \
> +                         crypto/odp_crypto_test_rng.c \
> +                         odp_crypto.c $(ODP_CU_COMMON)
> +dist_odp_init_SOURCES  = odp_init.c
> +dist_odp_pktio_SOURCES = odp_pktio.c $(ODP_CU_COMMON)
> +dist_odp_queue_SOURCES = odp_queue.c $(ODP_CU_COMMON)
> +dist_odp_schedule_SOURCES = odp_schedule.c $(ODP_CU_COMMON)
> +dist_odp_shm_SOURCES   = odp_shm.c $(ODP_CU_COMMON)
> +dist_odp_system_SOURCES = odp_system.c $(ODP_CU_COMMON)
> --
> 1.8.5.1.163.gd7aced9
>
>
> _______________________________________________
> lng-odp mailing list
> lng-odp@lists.linaro.org
> http://lists.linaro.org/mailman/listinfo/lng-odp
>
Maxim Uvarov Jan. 16, 2015, 11:27 a.m. UTC | #2
On 01/16/2015 01:15 AM, Mike Holmes wrote:
> This might make it clearer to users that there is a distinction 
> between tests and scripts that run tests but the patch no longer applies
>
> On 29 December 2014 at 09:19, Maxim Uvarov <maxim.uvarov@linaro.org 
> <mailto:maxim.uvarov@linaro.org>> wrote:
>
>     1. Reorder programs in Makefile.am to be in alphabetical order.
>     2. Put common source to variable.
>     3. Put source names on separate line to have less merge conflicts.
>
>     Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org
>     <mailto:maxim.uvarov@linaro.org>>
>     ---
>      v2: put scripts to variable list.
>
>      test/validation/Makefile.am | 53
>     +++++++++++++++++++++++++++++++--------------
>      1 file changed, 37 insertions(+), 16 deletions(-)
>
>     diff --git a/test/validation/Makefile.am b/test/validation/Makefile.am
>     index c0545b7..5a12ac9 100644
>     --- a/test/validation/Makefile.am
>     +++ b/test/validation/Makefile.am
>     @@ -4,26 +4,47 @@ AM_CFLAGS += -I$(srcdir)/common
>      AM_LDFLAGS += -static
>
>      TESTS_ENVIRONMENT = ODP_PLATFORM=${with_platform}
>     +#
>     +# BINS - list to compile and execute with make check
>
>
> call it EXECUTABLES and drop the comment ?
>
>     +#
>     +BINS = odp_buffer      \
>     +       odp_crypto      \
>     +       odp_init                \
>     +       odp_queue       \
>     +       odp_schedule    \
>     +       odp_shm         \
>     +       odp_system
>     +#
>     +# BINS_COMPILE - list to compile only
>
>
> would a variable called COMPILE_ONLY  be better and drop the comment ?
>
>     +#
>     +BINS_COMPILE = odp_pktio
>     +#
>     +# TSCRIPTS - list of scripts to be executed with make check
>     +#
>     +TSCRIPTS = odp_pktio_run
>
>
> Why T ?  TEST_SCRIPTS ? If so maybe we know they are tests scripts and 
> just call them SCRIPTS ?
> Can the TSCRIPTS list be generated from the BINS_COMPILE List  ?

TEST_SCRIPTS looks like keywork on configure.am. Variable name can not 
be crossed with keyword.

>
>      if ODP_CUNIT_ENABLED
>     -TESTS = odp_init odp_queue odp_crypto odp_shm odp_schedule
>     odp_pktio_run odp_buffer odp_system
>     -check_PROGRAMS = ${bin_PROGRAMS}
>     -bin_PROGRAMS = odp_init odp_queue odp_crypto odp_shm odp_schedule
>     odp_pktio odp_buffer odp_system
>     -odp_crypto_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/crypto
>     -odp_buffer_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/buffer
>     +TESTS = $(BINS) $(TSCRIPTS)
>     +bin_PROGRAMS = $(BINS) $(BINS_COMPILE)
>      endif
>
>     -dist_odp_init_SOURCES = odp_init.c
>     -dist_odp_pktio_SOURCES = odp_pktio.c common/odp_cunit_common.c
>     -dist_odp_queue_SOURCES = odp_queue.c common/odp_cunit_common.c
>     -dist_odp_crypto_SOURCES = crypto/odp_crypto_test_async_inp.c \
>     -  crypto/odp_crypto_test_sync_inp.c \
>     -                         crypto/odp_crypto_test_rng.c \
>     -                         odp_crypto.c common/odp_cunit_common.c
>     -dist_odp_shm_SOURCES = odp_shm.c common/odp_cunit_common.c
>     -dist_odp_schedule_SOURCES = odp_schedule.c common/odp_cunit_common.c
>     +check_PROGRAMS = ${bin_PROGRAMS}
>     +
>     +ODP_CU_COMMON=common/odp_cunit_common.c
>     +
>     +odp_buffer_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/buffer
>      dist_odp_buffer_SOURCES = buffer/odp_buffer_pool_test.c \
>                               buffer/odp_buffer_test.c \
>                               buffer/odp_packet_test.c \
>     -                         odp_buffer.c common/odp_cunit_common.c
>     -dist_odp_system_SOURCES = odp_system.c common/odp_cunit_common.c
>     +                         odp_buffer.c $(ODP_CU_COMMON)
>     +odp_crypto_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/crypto
>     +dist_odp_crypto_SOURCES = crypto/odp_crypto_test_async_inp.c \
>     +  crypto/odp_crypto_test_sync_inp.c \
>     +                         crypto/odp_crypto_test_rng.c \
>     +                         odp_crypto.c $(ODP_CU_COMMON)
>     +dist_odp_init_SOURCES  = odp_init.c
>     +dist_odp_pktio_SOURCES = odp_pktio.c $(ODP_CU_COMMON)
>     +dist_odp_queue_SOURCES = odp_queue.c $(ODP_CU_COMMON)
>     +dist_odp_schedule_SOURCES = odp_schedule.c $(ODP_CU_COMMON)
>     +dist_odp_shm_SOURCES   = odp_shm.c $(ODP_CU_COMMON)
>     +dist_odp_system_SOURCES = odp_system.c $(ODP_CU_COMMON)
>     --
>     1.8.5.1.163.gd7aced9
>
>
>     _______________________________________________
>     lng-odp mailing list
>     lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org>
>     http://lists.linaro.org/mailman/listinfo/lng-odp
>
>
>
>
> -- 
> *Mike Holmes*
> Linaro  Sr Technical Manager
> LNG - ODP
Mike Holmes Jan. 17, 2015, 3:53 a.m. UTC | #3
On 16 January 2015 at 06:27, Maxim Uvarov <maxim.uvarov@linaro.org> wrote:

> On 01/16/2015 01:15 AM, Mike Holmes wrote:
>
>> This might make it clearer to users that there is a distinction between
>> tests and scripts that run tests but the patch no longer applies
>>
>> On 29 December 2014 at 09:19, Maxim Uvarov <maxim.uvarov@linaro.org
>> <mailto:maxim.uvarov@linaro.org>> wrote:
>>
>>     1. Reorder programs in Makefile.am to be in alphabetical order.
>>     2. Put common source to variable.
>>     3. Put source names on separate line to have less merge conflicts.
>>
>>     Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org
>>     <mailto:maxim.uvarov@linaro.org>>
>>
>>     ---
>>      v2: put scripts to variable list.
>>
>>      test/validation/Makefile.am | 53
>>     +++++++++++++++++++++++++++++++--------------
>>      1 file changed, 37 insertions(+), 16 deletions(-)
>>
>>     diff --git a/test/validation/Makefile.am b/test/validation/Makefile.am
>>     index c0545b7..5a12ac9 100644
>>     --- a/test/validation/Makefile.am
>>     +++ b/test/validation/Makefile.am
>>     @@ -4,26 +4,47 @@ AM_CFLAGS += -I$(srcdir)/common
>>      AM_LDFLAGS += -static
>>
>>      TESTS_ENVIRONMENT = ODP_PLATFORM=${with_platform}
>>     +#
>>     +# BINS - list to compile and execute with make check
>>
>>
>> call it EXECUTABLES and drop the comment ?
>>
>>     +#
>>     +BINS = odp_buffer      \
>>     +       odp_crypto      \
>>     +       odp_init                \
>>     +       odp_queue       \
>>     +       odp_schedule    \
>>     +       odp_shm         \
>>     +       odp_system
>>     +#
>>     +# BINS_COMPILE - list to compile only
>>
>>
>> would a variable called COMPILE_ONLY  be better and drop the comment ?
>>
>>     +#
>>     +BINS_COMPILE = odp_pktio
>>     +#
>>     +# TSCRIPTS - list of scripts to be executed with make check
>>     +#
>>     +TSCRIPTS = odp_pktio_run
>>
>>
>> Why T ?  TEST_SCRIPTS ? If so maybe we know they are tests scripts and
>> just call them SCRIPTS ?
>> Can the TSCRIPTS list be generated from the BINS_COMPILE List  ?
>>
>
> TEST_SCRIPTS looks like keywork on configure.am. Variable name can not be
> crossed with keyword.
>

How about just SCRIPTS ?


>
>
>>      if ODP_CUNIT_ENABLED
>>     -TESTS = odp_init odp_queue odp_crypto odp_shm odp_schedule
>>     odp_pktio_run odp_buffer odp_system
>>     -check_PROGRAMS = ${bin_PROGRAMS}
>>     -bin_PROGRAMS = odp_init odp_queue odp_crypto odp_shm odp_schedule
>>     odp_pktio odp_buffer odp_system
>>     -odp_crypto_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/crypto
>>     -odp_buffer_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/buffer
>>     +TESTS = $(BINS) $(TSCRIPTS)
>>     +bin_PROGRAMS = $(BINS) $(BINS_COMPILE)
>>      endif
>>
>>     -dist_odp_init_SOURCES = odp_init.c
>>     -dist_odp_pktio_SOURCES = odp_pktio.c common/odp_cunit_common.c
>>     -dist_odp_queue_SOURCES = odp_queue.c common/odp_cunit_common.c
>>     -dist_odp_crypto_SOURCES = crypto/odp_crypto_test_async_inp.c \
>>     -  crypto/odp_crypto_test_sync_inp.c \
>>     -                         crypto/odp_crypto_test_rng.c \
>>     -                         odp_crypto.c common/odp_cunit_common.c
>>     -dist_odp_shm_SOURCES = odp_shm.c common/odp_cunit_common.c
>>     -dist_odp_schedule_SOURCES = odp_schedule.c common/odp_cunit_common.c
>>     +check_PROGRAMS = ${bin_PROGRAMS}
>>     +
>>     +ODP_CU_COMMON=common/odp_cunit_common.c
>>     +
>>     +odp_buffer_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/buffer
>>      dist_odp_buffer_SOURCES = buffer/odp_buffer_pool_test.c \
>>                               buffer/odp_buffer_test.c \
>>                               buffer/odp_packet_test.c \
>>     -                         odp_buffer.c common/odp_cunit_common.c
>>     -dist_odp_system_SOURCES = odp_system.c common/odp_cunit_common.c
>>     +                         odp_buffer.c $(ODP_CU_COMMON)
>>     +odp_crypto_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/crypto
>>     +dist_odp_crypto_SOURCES = crypto/odp_crypto_test_async_inp.c \
>>     +  crypto/odp_crypto_test_sync_inp.c \
>>     +                         crypto/odp_crypto_test_rng.c \
>>     +                         odp_crypto.c $(ODP_CU_COMMON)
>>     +dist_odp_init_SOURCES  = odp_init.c
>>     +dist_odp_pktio_SOURCES = odp_pktio.c $(ODP_CU_COMMON)
>>     +dist_odp_queue_SOURCES = odp_queue.c $(ODP_CU_COMMON)
>>     +dist_odp_schedule_SOURCES = odp_schedule.c $(ODP_CU_COMMON)
>>     +dist_odp_shm_SOURCES   = odp_shm.c $(ODP_CU_COMMON)
>>     +dist_odp_system_SOURCES = odp_system.c $(ODP_CU_COMMON)
>>     --
>>     1.8.5.1.163.gd7aced9
>>
>>
>>     _______________________________________________
>>     lng-odp mailing list
>>     lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org>
>>     http://lists.linaro.org/mailman/listinfo/lng-odp
>>
>>
>>
>>
>> --
>> *Mike Holmes*
>> Linaro  Sr Technical Manager
>> LNG - ODP
>>
>
>
diff mbox

Patch

diff --git a/test/validation/Makefile.am b/test/validation/Makefile.am
index c0545b7..5a12ac9 100644
--- a/test/validation/Makefile.am
+++ b/test/validation/Makefile.am
@@ -4,26 +4,47 @@  AM_CFLAGS += -I$(srcdir)/common
 AM_LDFLAGS += -static
 
 TESTS_ENVIRONMENT = ODP_PLATFORM=${with_platform}
+#
+# BINS - list to compile and execute with make check
+#
+BINS = odp_buffer	\
+       odp_crypto	\
+       odp_init		\
+       odp_queue	\
+       odp_schedule	\
+       odp_shm		\
+       odp_system
+#
+# BINS_COMPILE - list to compile only
+#
+BINS_COMPILE = odp_pktio
+#
+# TSCRIPTS - list of scripts to be executed with make check
+#
+TSCRIPTS = odp_pktio_run
 
 if ODP_CUNIT_ENABLED
-TESTS = odp_init odp_queue odp_crypto odp_shm odp_schedule odp_pktio_run odp_buffer odp_system
-check_PROGRAMS = ${bin_PROGRAMS}
-bin_PROGRAMS = odp_init odp_queue odp_crypto odp_shm odp_schedule odp_pktio odp_buffer odp_system
-odp_crypto_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/crypto
-odp_buffer_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/buffer
+TESTS = $(BINS) $(TSCRIPTS)
+bin_PROGRAMS = $(BINS) $(BINS_COMPILE)
 endif
 
-dist_odp_init_SOURCES = odp_init.c
-dist_odp_pktio_SOURCES = odp_pktio.c common/odp_cunit_common.c
-dist_odp_queue_SOURCES = odp_queue.c common/odp_cunit_common.c
-dist_odp_crypto_SOURCES = crypto/odp_crypto_test_async_inp.c \
-			  crypto/odp_crypto_test_sync_inp.c \
-			  crypto/odp_crypto_test_rng.c \
-			  odp_crypto.c common/odp_cunit_common.c
-dist_odp_shm_SOURCES = odp_shm.c common/odp_cunit_common.c
-dist_odp_schedule_SOURCES = odp_schedule.c common/odp_cunit_common.c
+check_PROGRAMS = ${bin_PROGRAMS}
+
+ODP_CU_COMMON=common/odp_cunit_common.c
+
+odp_buffer_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/buffer
 dist_odp_buffer_SOURCES = buffer/odp_buffer_pool_test.c \
 			  buffer/odp_buffer_test.c \
 			  buffer/odp_packet_test.c \
-			  odp_buffer.c common/odp_cunit_common.c
-dist_odp_system_SOURCES = odp_system.c common/odp_cunit_common.c
+			  odp_buffer.c $(ODP_CU_COMMON)
+odp_crypto_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/crypto
+dist_odp_crypto_SOURCES = crypto/odp_crypto_test_async_inp.c \
+			  crypto/odp_crypto_test_sync_inp.c \
+			  crypto/odp_crypto_test_rng.c \
+			  odp_crypto.c $(ODP_CU_COMMON)
+dist_odp_init_SOURCES	= odp_init.c
+dist_odp_pktio_SOURCES	= odp_pktio.c $(ODP_CU_COMMON)
+dist_odp_queue_SOURCES	= odp_queue.c $(ODP_CU_COMMON)
+dist_odp_schedule_SOURCES = odp_schedule.c $(ODP_CU_COMMON)
+dist_odp_shm_SOURCES	= odp_shm.c $(ODP_CU_COMMON)
+dist_odp_system_SOURCES = odp_system.c $(ODP_CU_COMMON)