[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to make a working ld in guix pure environment?

From: Fis Trivial
Subject: How to make a working ld in guix pure environment?
Date: Thu, 24 May 2018 18:14:07 +0000

Hi, I'm working to get OpenCL into guix. In the OpenCL world, source
code for devices (such as GPU or FPGA or just CPU) is shipped as string
and embeded in the binary object, then latter compiled by OpenCL
implementation at runtime.

So, a correct linker at runtime is necessary for runing OpenCL
program, but I don't know how to achieve it.

I tried to use ld in guix pure environment, tested with bintuils,
gcc-toolchain, ld-wrapper, and none of them work.

Take the following trivial snippy (not opencl related) as an example:

// main.c
#include <math.h>

int main()

To build it, one would do something similar to `ld -lm main.o` after
compilation. But I got an error saying "ld: cannot find -lm".

I have a little chat with @lfam at IRC (thanks:) ). In order to clear
one of the confusions, please know that ld needed to be used standalone,
not with gcc-toolchain, since it's needed at target program runtime.

Please give me some advices about making a correct ld.

Thanks in advance.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]