Difference between revisions of "LDC+Dub+Vibe.d on SmartOS 64bit"

From D Wiki
Jump to: navigation, search
(Created page with "1. Create “minimal-64-lts” zone with quota~10G and RAM~4G 2. If internet connection available only behind proxy, add proxy env to .bashrc * ''# echo “export http_proxy=...")
 
Line 16: Line 16:
 
7. Clone llvm repository and set last release
 
7. Clone llvm repository and set last release
 
* ''# git clone --recursive https://github.com/llvm-mirror/llvm.git''
 
* ''# git clone --recursive https://github.com/llvm-mirror/llvm.git''
 +
* ''# cd llvm''
 
* ''# git checkout release_38''
 
* ''# git checkout release_38''
 
8. Correct AddLLVM.cmake in ./llvm/cmake/modules/AddLLVM.cmake. Change phrase <''discard_unused=sections''> to <''ignore''>.
 
8. Correct AddLLVM.cmake in ./llvm/cmake/modules/AddLLVM.cmake. Change phrase <''discard_unused=sections''> to <''ignore''>.
  
 
9. Configure llvm only for one platform because it will be very long time building :-)
 
9. Configure llvm only for one platform because it will be very long time building :-)
* ''# mkdir build_llvm''
+
* ''# mkdir ~/work/build_llvm''
 
* ''# cd $_''
 
* ''# cd $_''
 
* ''# cmake -DCMAKE_BUILD_TYPE=”Release” -DLLVM_TARGETS_TO_BUILD=”X86” ../llvm/''
 
* ''# cmake -DCMAKE_BUILD_TYPE=”Release” -DLLVM_TARGETS_TO_BUILD=”X86” ../llvm/''

Revision as of 10:44, 9 June 2016

1. Create “minimal-64-lts” zone with quota~10G and RAM~4G

2. If internet connection available only behind proxy, add proxy env to .bashrc

3. Restart bashrc

  • # . ~/.bashrc

4. Install needed packages

  • # pkgin up
  • # pkgin in binutils gmake cmake scmgit python35 autoconf gcc49 gcc49-libs unzip libconfig livevent

5. All manipulations I did from work directory, so create it

  • # mkdir work
  • # cd work

6. Set git protocol (need if proxy not work with git url)

7. Clone llvm repository and set last release

8. Correct AddLLVM.cmake in ./llvm/cmake/modules/AddLLVM.cmake. Change phrase <discard_unused=sections> to <ignore>.

9. Configure llvm only for one platform because it will be very long time building :-)

  • # mkdir ~/work/build_llvm
  • # cd $_
  • # cmake -DCMAKE_BUILD_TYPE=”Release” -DLLVM_TARGETS_TO_BUILD=”X86” ../llvm/

10. Build and install llvm

  • # gmake -j5
  • # gmake install

11. For this moment (09.06.2016) in SmartOS package repositories libLLVM-3.7.0 is available. Alternatively you can try to install libLLVM-3.7.0 with pkgin manager, but this path not tested yet. Therefore in this howto used newer release of LLVM, that build from source.