Re: [gentoo-dev] [PATCH v2 1/2] rocm.eclass: new eclass

2022-08-17 Thread Ulrich Mueller
> On Wed, 17 Aug 2022, wuyy wrote: > Also, I have some long sentences in code, for throwing information. How > do I nicely wrap such long strings in bash? By incremental assigning it > to variables I guess? It's not an absolute rule. Avoid long lines where possible, but don't jump through ho

Re: [gentoo-dev] [PATCH v2 1/2] rocm.eclass: new eclass

2022-08-16 Thread wuyy
Thank you very much for pointing out so much problems I missed! On Tue, Aug 16, 2022 at 12:41:47AM +0200, Ulrich Mueller wrote: > Please wrap lines at below 80 character positions. (This applies both to > documentation and to code.) > Thanks. Seems that I forgot yo run re-wrapping in a final rou

Re: [gentoo-dev] [PATCH v2 1/2] rocm.eclass: new eclass

2022-08-15 Thread Ulrich Mueller
> On Mon, 15 Aug 2022, Yiyang Wu wrote: > +_rocm_set_globals() { > + case ${ROCM_VERSION:-${PV}} in > + 4*) What will happen when there's a version 40 in the future? signature.asc Description: PGP signature

Re: [gentoo-dev] [PATCH v2 1/2] rocm.eclass: new eclass

2022-08-15 Thread Ulrich Mueller
> On Tue, 16 Aug 2022, Ulrich Mueller wrote: >> +IUSE+=" ${gpu_target/#/+amdgpu_targets_}" > Why "+="? I don't see any previous assignment of IUSE. Please ignore this. I had missed that it's inside a loop. signature.asc Description: PGP signature

Re: [gentoo-dev] [PATCH v2 1/2] rocm.eclass: new eclass

2022-08-15 Thread Ulrich Mueller
> On Mon, 15 Aug 2022, Yiyang Wu wrote: > diff --git a/eclass/rocm.eclass b/eclass/rocm.eclass > new file mode 100644 > index ..8ca2c051ddce > --- /dev/null > +++ b/eclass/rocm.eclass > @@ -0,0 +1,275 @@ > +# Copyright 2022 Gentoo Authors > +# Distributed under the terms of the GNU

[gentoo-dev] [PATCH v2 1/2] rocm.eclass: new eclass

2022-08-15 Thread Yiyang Wu
This eclass provides utilities for ROCm libraries in https://github.com/ROCmSoftwarePlatform, e.g. rocBLAS, rocFFT. It contains a USE_EXPAND, amdgpu_targets_*, which handles the GPU architecture to compile, and keep targets coherent among dependencies. Packages that depend on ROCm libraries, like c