On 12/6/2017 4:53 PM, Hans Petter Selasky wrote:
> On 12/07/17 01:38, Bryan Drewery wrote:
>> 1. SUBDIR=../../somewhere else is inherently wrong.
>> 2. Building a library from a directory named '2' is wrong.
>> 3. Not just using proper SUBDIR_DEPEND and making all these subdirs is
>> not needed and complicates things MORE by splitting them all up.
>> 4. Building a library from a directory where its real bsd.lib.mk is not
>> at is wrong.
>> 5. Depending on an include directory in the Makefile.inc1 library
>> dependencies is simply not needed - I told you that.
> 
> Try building the COMPAT 32-bit libraries with OFED and you'll see that
> this is needed!
> 
>> 6. Using these /0 /1 /2 /3 directories actually hurts the 'make
>> libraries' parallelism/dependency graph. It ends up building /1 rather
>> than building libibcm and libibumad directly in its graph.  It creates
>> an indirection which adds more unneeded submake recursion.
> 
> I think this is no argument over having to maintain and update
> Makefile.inc1 with all the dependencies every time there is a change or
> new driver library added to OFED.

Here's the proper change to contrib/ofed/usr.lib/Makefile, it is trivial.

> diff --git contrib/ofed/usr.lib/Makefile contrib/ofed/usr.lib/Makefile
> index 47b97591f5b7..9c22b889fa19 100644
> --- contrib/ofed/usr.lib/Makefile
> +++ contrib/ofed/usr.lib/Makefile
> @@ -1,13 +1,24 @@
> -SUBDIR=        libibcommon libibmad libibumad libibverbs libmlx4 libmthca \
> -       libopensm libosmcomp libosmvendor libibcm librdmacm libsdp libcxgb4
> +SUBDIR= \
> +       libibverbs \
> +       libibcm \
> +       libibumad \
> +       librdmacm \
> +       libibmad \
> +       libosmcomp \
> +       libosmvendor \
> +       libcxgb4 \
> +       libmlx4 \
> +       libmlx5 \
> +       libibnetdisc \
> +       libopensm
> 
>  SUBDIR_DEPEND_libcxgb4=        libibverbs
>  SUBDIR_DEPEND_libibcm= libibverbs
> -SUBDIR_DEPEND_libibmad= libibcommon libibumad
> -SUBDIR_DEPEND_libibumad= libibcommon
> +SUBDIR_DEPEND_libibmad=        libibumad
> +SUBDIR_DEPEND_libibnetdisc=    libosmcomp libibmad libibumad
>  SUBDIR_DEPEND_libmlx4= libibverbs
> -SUBDIR_DEPEND_libmthca=        libibverbs
> -SUBDIR_DEPEND_libosmvendor=    libibumad libopensm libosmcomp
> +SUBDIR_DEPEND_libmlx5= libibverbs
> +SUBDIR_DEPEND_libosmvendor=    libibumad
>  SUBDIR_DEPEND_librdmacm=       libibverbs
>  SUBDIR_PARALLEL=
> 

And Makefile.inc1 which is even more simple.

> @@ -2365,14 +2414,12 @@ _lib_libradius= lib/libradius
>  .if ${MK_OFED} != "no"
>  _ofed_lib=             contrib/ofed/usr.lib
>  _prebuild_libs+=       contrib/ofed/usr.lib/libosmcomp
> -_prebuild_libs+=       contrib/ofed/usr.lib/libopensm
> -_prebuild_libs+=       contrib/ofed/usr.lib/libibcommon
>  _prebuild_libs+=       contrib/ofed/usr.lib/libibverbs
> +_prebuild_libs+=       contrib/ofed/usr.lib/libibmad
>  _prebuild_libs+=       contrib/ofed/usr.lib/libibumad
> 
> -contrib/ofed/usr.lib/libopensm__L: lib/libthr__L
>  contrib/ofed/usr.lib/libosmcomp__L: lib/libthr__L
> -contrib/ofed/usr.lib/libibumad__L: contrib/ofed/usr.lib/libibcommon__L
> +contrib/ofed/usr.lib/libibmad__L: contrib/ofed/usr.lib/libibumad__L
>  .endif


-- 
Regards,
Bryan Drewery

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to