Jump to page: 1 2
Thread overview
Failed installation of LDC
Jun 09, 2016
LDC_Installer
Jun 09, 2016
LDC_Installer
Jun 10, 2016
Johan Engelen
Jun 10, 2016
LDC_Installer
Jun 10, 2016
Johan Engelen
Jun 10, 2016
LDC_Installer
[SOLVED] Re: Failed installation of LDC
Jun 10, 2016
LDC_Installer
Jun 10, 2016
Johan Engelen
Jun 10, 2016
LDC_Installer
Re: [SOLVED] Failed installation of LDC
Jun 10, 2016
David Nadlinger
Jun 10, 2016
LDC_Installer
June 09, 2016
Hi there, I've followed exactly the "how to install LDC" guide on the dlang.org download page. LLVM 3.7.1 is installed with target being x64. Then I've downloaded ldc and updated the submodules. Next step was the call to "cmake -DLIB_SUFFIX=64 .." in the build directory, followed by "make". This is the error message I get:

/home/username/Downloads/ldc/driver/linker.cpp: At global scope:
/home/username/Downloads/ldc/driver/linker.cpp:35:13: warning: ‘bool endsWith(const string&, const string&)’ defined but not used [-Wunused-function]
 static bool endsWith(const std::string &str, const std::string &end) {
             ^
make[2]: *** [CMakeFiles/LDCShared.dir/driver/linker.cpp.o] Fehler 1
make[1]: *** [CMakeFiles/LDCShared.dir/all] Fehler 2
make: *** [all] Fehler 2

Also, I've got DMD v2.071.0 installed.
Any suggestions how to resolve this?
June 09, 2016
On Thursday, 9 June 2016 at 23:04:07 UTC, LDC_Installer wrote:
> Hi there, I've followed exactly the "how to install LDC" guide on the dlang.org download page. LLVM 3.7.1 is installed with target being x64. Then I've downloaded ldc and updated the submodules. Next step was the call to "cmake -DLIB_SUFFIX=64 .." in the build directory, followed by "make". This is the error message I get:
>
> /home/username/Downloads/ldc/driver/linker.cpp: At global scope:
> /home/username/Downloads/ldc/driver/linker.cpp:35:13: warning: ‘bool endsWith(const string&, const string&)’ defined but not used [-Wunused-function]
>  static bool endsWith(const std::string &str, const std::string &end) {
>              ^
> make[2]: *** [CMakeFiles/LDCShared.dir/driver/linker.cpp.o] Fehler 1
> make[1]: *** [CMakeFiles/LDCShared.dir/all] Fehler 2
> make: *** [all] Fehler 2
>
> Also, I've got DMD v2.071.0 installed.
> Any suggestions how to resolve this?

Here's what I get when running make:

/home/username/Downloads/ldc/driver/linker.cpp: In function ‘void {anonymous}::insertBitcodeIntoModule(const char*, llvm::Module&, llvm::LLVMContext&)’:
/home/username/Downloads/ldc/driver/linker.cpp:124:17: error: no matching function for call to ‘llvm::Linker::Linker(llvm::Module&)’
   llvm::Linker(M).linkInModule(std::move(loadedModule));
                 ^
/home/username/Downloads/ldc/driver/linker.cpp:124:17: note: candidates are:
In file included from /home/username/Downloads/ldc/driver/linker.cpp:23:0:
/usr/local/include/llvm/Linker/Linker.h:64:3: note: llvm::Linker::Linker(llvm::Module*)
   Linker(Module *M);
   ^
/usr/local/include/llvm/Linker/Linker.h:64:3: note:   no known conversion for argument 1 from ‘llvm::Module’ to ‘llvm::Module*’
/usr/local/include/llvm/Linker/Linker.h:63:3: note: llvm::Linker::Linker(llvm::Module*, llvm::DiagnosticHandlerFunction)
   Linker(Module *M, DiagnosticHandlerFunction DiagnosticHandler);
   ^
/usr/local/include/llvm/Linker/Linker.h:63:3: note:   candidate expects 2 arguments, 1 provided
/usr/local/include/llvm/Linker/Linker.h:27:7: note: llvm::Linker::Linker(const llvm::Linker&)
 class Linker {
       ^
/usr/local/include/llvm/Linker/Linker.h:27:7: note:   no known conversion for argument 1 from ‘llvm::Module’ to ‘const llvm::Linker&’
/home/username/Downloads/ldc/driver/linker.cpp: In function ‘void deleteExecutable()’:
/home/username/Downloads/ldc/driver/linker.cpp:725:10: warning: unused variable ‘is_directory’ [-Wunused-variable]
     bool is_directory;
          ^
/home/username/Downloads/ldc/driver/linker.cpp: At global scope:
/home/username/Downloads/ldc/driver/linker.cpp:35:13: warning: ‘bool endsWith(const string&, const string&)’ defined but not used [-Wunused-function]
 static bool endsWith(const std::string &str, const std::string &end) {
             ^
make[2]: *** [CMakeFiles/LDCShared.dir/driver/linker.cpp.o] Fehler 1
make[1]: *** [CMakeFiles/LDCShared.dir/all] Fehler 2
make: *** [all] Fehler 2

June 10, 2016
On Thursday, 9 June 2016 at 23:08:44 UTC, LDC_Installer wrote:
>
> Here's what I get when running make:
>
> /home/username/Downloads/ldc/driver/linker.cpp: In function ‘void {anonymous}::insertBitcodeIntoModule(const char*, llvm::Module&, llvm::LLVMContext&)’:
> /home/username/Downloads/ldc/driver/linker.cpp:124:17: error: no matching function for call to ‘llvm::Linker::Linker(llvm::Module&)’
>    llvm::Linker(M).linkInModule(std::move(loadedModule));
>                  ^

This is my fault I think. Looks like building master is broken for LLVM < 3.8. Working on a fix. Thanks a lot for reporting!

-Johan

June 10, 2016
On Friday, 10 June 2016 at 09:18:53 UTC, Johan Engelen wrote:
> On Thursday, 9 June 2016 at 23:08:44 UTC, LDC_Installer wrote:
>>
>> Here's what I get when running make:
>>
>> /home/username/Downloads/ldc/driver/linker.cpp: In function ‘void {anonymous}::insertBitcodeIntoModule(const char*, llvm::Module&, llvm::LLVMContext&)’:
>> /home/username/Downloads/ldc/driver/linker.cpp:124:17: error: no matching function for call to ‘llvm::Linker::Linker(llvm::Module&)’
>>    llvm::Linker(M).linkInModule(std::move(loadedModule));
>>                  ^
>
> This is my fault I think. Looks like building master is broken for LLVM < 3.8. Working on a fix. Thanks a lot for reporting!
>
> -Johan

"LLVM < 3.8" Does that mean LLVM 3.8 should work properly?
June 10, 2016
On Friday, 10 June 2016 at 10:06:28 UTC, LDC_Installer wrote:
> On Friday, 10 June 2016 at 09:18:53 UTC, Johan Engelen wrote:
>> On Thursday, 9 June 2016 at 23:08:44 UTC, LDC_Installer wrote:
>>>
>>> Here's what I get when running make:
>>>
>>> /home/username/Downloads/ldc/driver/linker.cpp: In function ‘void {anonymous}::insertBitcodeIntoModule(const char*, llvm::Module&, llvm::LLVMContext&)’:
>>> /home/username/Downloads/ldc/driver/linker.cpp:124:17: error: no matching function for call to ‘llvm::Linker::Linker(llvm::Module&)’
>>>    llvm::Linker(M).linkInModule(std::move(loadedModule));
>>>                  ^
>>
>> This is my fault I think. Looks like building master is broken for LLVM < 3.8. Working on a fix. Thanks a lot for reporting!
>>
>> -Johan
>
> "LLVM < 3.8" Does that mean LLVM 3.8 should work properly?

Definitely.
June 10, 2016
>
> Definitely.

Thanks! I'll give it a shot
June 10, 2016
>>
>> "LLVM < 3.8" Does that mean LLVM 3.8 should work properly?
>
> Definitely.

It does work.
I still have to reconfigure and re-run since Mint can't seem to find the ldc executable after sudo installing llvm 3.8 (according to http://llvm.org/docs/CMake.html) and sudo installing ldc (according to http://wiki.dlang.org/Building_LDC_from_source)
June 10, 2016
On Friday, 10 June 2016 at 15:54:05 UTC, LDC_Installer wrote:
>>>
>>> "LLVM < 3.8" Does that mean LLVM 3.8 should work properly?
>>
>> Definitely.
>
> It does work.
> I still have to reconfigure and re-run since Mint can't seem to find the ldc executable after sudo installing llvm 3.8 (according to http://llvm.org/docs/CMake.html) and sudo installing ldc (according to http://wiki.dlang.org/Building_LDC_from_source)

I also fixed master for LLVM 3.7.
June 10, 2016
On Friday, 10 June 2016 at 17:34:17 UTC, Johan Engelen wrote:
> On Friday, 10 June 2016 at 15:54:05 UTC, LDC_Installer wrote:
>>>>
>>>> "LLVM < 3.8" Does that mean LLVM 3.8 should work properly?
>>>
>>> Definitely.
>>
>> It does work.
>> I still have to reconfigure and re-run since Mint can't seem to find the ldc executable after sudo installing llvm 3.8 (according to http://llvm.org/docs/CMake.html) and sudo installing ldc (according to http://wiki.dlang.org/Building_LDC_from_source)
>
> I also fixed master for LLVM 3.7.

Good to know, but too late :D

Anyway, you might want to pardon this probably silly question: How do I invoke LDC? As I mentioned before I'd installed both LLVM and LDC via sudo make install. But no command I can think of and run will trigger LDC. ldc, lldc, lld, llvm-ldc or whatever won't work.
June 10, 2016
On 10 Jun 2016, at 18:53, LDC_Installer via digitalmars-d-ldc wrote:
> Good to know, but too late :D

Sorry for the hassle – just in case anybody is wondering, this could only happen because our CI system is currently hamstrung by the LLVM APT repositories being temporarily offline.

> ldc, lldc, lld, llvm-ldc or whatever won't work.

The binary names are ldc2 for the "native" driver and ldmd2 for the DMD compatibility wrapper.

 — David
« First   ‹ Prev
1 2