Thanks a lot!

On Mon, 11 Jul 2022 at 16:18, Rui Huang <vows...@gmail.com> wrote:

> Hi,
>
> The latest libnvidia-container-1.10.0 has been tested and committed to the
> dev branch of the ::guru overlay (waiting to be merged into the master
> branch)
>
>
> https://github.com/gentoo/guru/commit/9edb349a59c3479b53ffa4049e220ee223aeb0ec
>
> And the matching app-containers/nvidia-container-toolkit-1.10.0 has also
> been committed to the dev branch.
> After waiting for the merge, you can directly use the ebuild in the ::guru
> overlay.
>
>
> https://github.com/gentoo/guru/commit/350c753f97903397f5fe8f9c05f815007e339018
>
> Best regards,
> Huang Rui
>
> On Mon, 11 Jul 2022 at 12:35, Andrew Ammerlaan <andrewammerl...@gentoo.org>
> wrote:
>
>> Hi,
>>
>> On 11/07/2022 05:17, Xi Shen wrote:
>> > Hi,
>> >
>> > I am trying to create an ebuild file for
>> > https://github.com/NVIDIA/libnvidia-container
>> > <https://github.com/NVIDIA/libnvidia-container>. It has a few other
>> > dependencies which will be built by itself.
>>
>> Such an ebuild already exists in the ::guru overlay (maintainer in CC).
>> I see it is one version behind though. Feel free to bump it to the
>> latest version if you want, probably a simple copy and renaming of the
>> ebuild will do the trick.
>>
>> > My ebuild can download and compile those dependencies. But one of the
>> > dependency "libtirpc-1.3.2" needs to install itself in the temporary
>> > portage environment. Its Makefile allows me to pass in the "DESTDIR"
>> > variable which I passed in
>> >
>> "/var/tmp/portage/sys-libs/libnvidia-container-1.10.0/work/libnvidia-container-1.10.0/deps",
>>
>> > but when it installs, the package is installed to
>> >
>> "/var/tmp/portage/sys-libs/libnvidia-container-1.10.0/work/libnvidia-container-1.10.0/deps/var/tmp/portage/sys-libs/libnvidia-container-1.10.0/work/libnvidia-container-1.10.0/deps/usr/local",
>>
>> > the working director got repeated after the "deps" directory.
>> >
>> > I checked the makefile, but could not figure out where that path got
>> > replicated. I guess when running inside the portage build environment,
>> > there's some "chroot" trick that prevents packages from writing the
>> root
>> > file system.
>> >
>> > So I want to ask if I need to do a "make install" during compilation,
>> > how should I pass the destination directory?
>>
>> Don't try to install things to the installation directory (${ED}) during
>> the compile phase. If you really have something that insists on being
>> installed somewhere to complete the compilation, then install it to some
>> temporary directory, e.g. ${T} and then if necessary copy it from the
>> temporary directory into the installation directory during the install
>> phase. The ebuild in ::guru seems to solve your problem with a bunch of
>> patches, which I think is a better solution.
>>
>> Best regards,
>> Andrew
>>
>

Reply via email to