Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 799257 - dev-util/hip-4.2.0 version bump
Summary: dev-util/hip-4.2.0 version bump
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Science Related Packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-06-29 16:56 UTC by Dennis Schridde
Modified: 2021-08-13 05:08 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,92.05 KB, text/x-log)
2021-07-19 04:46 UTC, justXi
Details
hip-4.1_4.2.patch (hip-4.1_4.2.patch,5.17 KB, patch)
2021-07-19 11:35 UTC, Benda Xu
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dennis Schridde 2021-06-29 16:56:32 UTC
Version 4.2.0 of dev-util/hip matching sys-devel/llvm-roc-4.2.0 was released on 2021-05-11: https://github.com/ROCm-Developer-Tools/HIP/releases/tag/rocm-4.2.0

Version 4.1.1 of dev-util/hip matching sys-devel/llvm-roc-4.1.1 was released on 2021-04-08: https://github.com/ROCm-Developer-Tools/HIP/releases/tag/rocm-4.1.1

It would be nice to have these versions in Gentoo, to allow upgrading llvm-roc and the rest of the ROCm ecosystem.
Comment 1 justXi 2021-07-01 15:04:00 UTC
I am currently working on that... but there is still a sandbox violation while installing the files. I will create a PR as soon as possible.
Comment 2 justXi 2021-07-01 15:24:08 UTC
If someone wants to give it a try and maybe has an idea how to solve... I have pushed the current state of the ebuild and patches to my repository (beta state!) -> https://github.com/justxi/rocm/tree/master/dev-util/hip
Comment 3 Yiyang Wu 2021-07-16 16:09:41 UTC
I created a PR at https://github.com/gentoo/gentoo/pull/21655, which contains the hip-4.2.0.ebuild and an updated patch. The ebuild is identical to the one in https://github.com/justxi/rocm/tree/master/dev-util/hip and the patches have the same effect. According to Benda Xu, we need a further explanation of the updated patch.
Comment 4 justXi 2021-07-16 16:14:50 UTC
Interesting... I had a problem with the installation... Did you solve this?
Comment 5 Benda Xu gentoo-dev 2021-07-17 04:30:59 UTC
(In reply to Wu Yiyang from comment #3)
> I created a PR at https://github.com/gentoo/gentoo/pull/21655, which
> contains the hip-4.2.0.ebuild and an updated patch. The ebuild is identical
> to the one in https://github.com/justxi/rocm/tree/master/dev-util/hip and
> the patches have the same effect. According to Benda Xu, we need a further
> explanation of the updated patch.

It is too much work for existing patches.  Let's just enforce this policy on the newly added patches and improve the ebuild quality incrementally.
Comment 6 Benda Xu gentoo-dev 2021-07-17 04:32:05 UTC
(In reply to justXi from comment #4)
> Interesting... I had a problem with the installation... Did you solve this?

Could you please elaborate on the errors encountered, hopefully with a build.log.
Comment 7 Yiyang Wu 2021-07-17 05:43:33 UTC
(In reply to justXi from comment #4)
> Interesting... I had a problem with the installation... Did you solve this?

I installed and ran hip-4.2.0 successfully in gentoo prefix. Is this problem related to the sandbox violation?
Comment 8 justXi 2021-07-17 06:03:29 UTC
Yes, my problem was related to a sandbox violation. I will add a build log later.
Comment 9 justXi 2021-07-19 04:46:26 UTC
Created attachment 724933 [details]
build.log

Please find attached my build.log.
Comment 10 Benda Xu gentoo-dev 2021-07-19 10:26:09 UTC
(In reply to justXi from comment #9)
> Created attachment 724933 [details]
> build.log
> 
> Please find attached my build.log.

The offending code is at

> Removing /usr/lib/hip/include
>  * ACCESS DENIED:  chmod:        /usr/lib/hip/include
>  * ACCESS DENIED:  chmod:        /usr/lib/hip/include/hip
>  * ACCESS DENIED:  unlink:       /usr/lib/hip/include/hip/hip_hcc.h

The logic is to make sure the destination does no have an existing hip_hcc.h file, which is deprecated.  Gentoo does not need this, let's patch this out in the build system and we are ready to go.
Comment 11 justXi 2021-07-19 10:48:53 UTC
I didn´t find the point, where it is included. But I will check it again.
Comment 12 Benda Xu gentoo-dev 2021-07-19 11:35:37 UTC
Created attachment 725149 [details, diff]
hip-4.1_4.2.patch

(In reply to justXi from comment #11)
> I didn´t find the point, where it is included. But I will check it again.

It's at HIP-rocm-4.2.0/CMakeLists.txt:336

>  # The following two lines will be removed after upstream updation
>  install(CODE "MESSAGE(\"Removing ${CMAKE_INSTALL_PREFIX}/include\")")
>  install(CODE "file(REMOVE_RECURSE ${CMAKE_INSTALL_PREFIX}/include)")

which is introduced by hip-4.2.
Comment 13 justXi 2021-07-19 12:09:41 UTC
(In reply to Benda Xu from comment #12)

> It's at HIP-rocm-4.2.0/CMakeLists.txt:336
> 
> >  # The following two lines will be removed after upstream updation
> >  install(CODE "MESSAGE(\"Removing ${CMAKE_INSTALL_PREFIX}/include\")")
> >  install(CODE "file(REMOVE_RECURSE ${CMAKE_INSTALL_PREFIX}/include)")
> 
> which is introduced by hip-4.2.

Of course ;-)... it´s little bit hidden :(...

But I removed these lines and removed a directory from "${D}..." and now HIP install. 

My version is in https://github.com/justxi/rocm/blob/master/dev-util/hip/hip-4.2.0.ebuild again. 

Maybe Wu Yiyang wants to adopt it?
Comment 14 Larry the Git Cow gentoo-dev 2021-08-13 05:08:17 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7f9224da75c864396af5693c2e5b3dbbd0f529c1

commit 7f9224da75c864396af5693c2e5b3dbbd0f529c1
Author:     YiyangWu <xgreenlandforwyy@gmail.com>
AuthorDate: 2021-07-15 15:19:15 +0000
Commit:     Benda Xu <heroxbd@gentoo.org>
CommitDate: 2021-08-13 05:08:09 +0000

    dev-util/hip: bump version to 4.2.0
    
    Update hip-3.5.1-config-cmake-in.patch to 4.2.0
    lpl_ca removed, so hip-3.9.0-lpl_ca-add-include.patch not used
    fill version into hipvars.pm at src_prepare
    fix sandbox violation issue
    remove linker flag -rpath in hipcc
    correct profiling api header location and profile use flag settings
    
    Closes: https://bugs.gentoo.org/799257
    Closes: https://github.com/gentoo/gentoo/pull/21655
    
    Package-Manager: Portage-3.0.20, Repoman-3.0.3
    Signed-off-by: Yiyang Wu <xgreenlandforwyy@gmail.com>
    Signed-off-by: Benda Xu <heroxbd@gentoo.org>

 dev-util/hip/Manifest                              |   1 +
 .../hip-4.2.0-cancel-hcc-header-removal.patch      |  18 ++++
 dev-util/hip/files/hip-4.2.0-config-cmake-in.patch |  15 +++
 dev-util/hip/files/hipvars.pm                      |   7 +-
 dev-util/hip/hip-4.1.0-r1.ebuild                   |   2 +
 dev-util/hip/hip-4.2.0.ebuild                      | 108 +++++++++++++++++++++
 6 files changed, 148 insertions(+), 3 deletions(-)