main.yml 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. name: build-opencl
  2. on: [push]
  3. jobs:
  4. windows_opencl:
  5. name: opencl/release/windows
  6. runs-on: [windows-latest]
  7. steps:
  8. - uses: actions/checkout@v2
  9. - uses: msys2/setup-msys2@v2
  10. - name: setup
  11. run: |
  12. msys2 -c 'wget https://github.com/GPUOpen-LibrariesAndSDKs/OCL-SDK/files/1406216/lightOCLSDK.zip -O amdocl.zip'
  13. jar xf amdocl.zip
  14. - name: build
  15. run: |
  16. echo "D:\a\kaktwoos-cl\kaktwoos-cl\lib\x86_64\;D:\a\kaktwoos-cl\kaktwoos-cl\include\" >> $GITHUB_PATH
  17. g++ -w -static -m64 -Ofast -lstdc++ .\main-nv.c -o kaktwoos-ocl-nv.exe -LD:\a\kaktwoos-cl\kaktwoos-cl\lib\x86_64\ -ID:\a\kaktwoos-cl\kaktwoos-cl\include\ -ID:\a\kaktwoos-cl\kaktwoos-cl\boinc\ -ID:\a\kaktwoos-cl\kaktwoos-cl\boinc\win\ -LD:\a\kaktwoos-cl\kaktwoos-cl\boinc\lib\win\ -lboinc_api -lboinc -lboinc_opencl -lOpenCL -D_WIN64 -DWIN64 -D_WIN32 -DWIN32 -DWANTED_CACTUS_HEIGHT=21
  18. g++ -w -static -m64 -Ofast -lstdc++ .\main-amd.c -o kaktwoos-ocl-amd.exe -LD:\a\kaktwoos-cl\kaktwoos-cl\lib\x86_64\ -ID:\a\kaktwoos-cl\kaktwoos-cl\include\ -ID:\a\kaktwoos-cl\kaktwoos-cl\boinc\ -ID:\a\kaktwoos-cl\kaktwoos-cl\boinc\win\ -LD:\a\kaktwoos-cl\kaktwoos-cl\boinc\lib\win\ -lboinc_api -lboinc -lboinc_opencl -lOpenCL -D_WIN64 -DWIN64 -D_WIN32 -DWIN32 -DWANTED_CACTUS_HEIGHT=21
  19. g++ -w -static -m64 -Ofast -lstdc++ .\main-intel.c -o kaktwoos-ocl-intel.exe -LD:\a\kaktwoos-cl\kaktwoos-cl\lib\x86_64\ -ID:\a\kaktwoos-cl\kaktwoos-cl\include\ -ID:\a\kaktwoos-cl\kaktwoos-cl\boinc\ -ID:\a\kaktwoos-cl\kaktwoos-cl\boinc\win\ -LD:\a\kaktwoos-cl\kaktwoos-cl\boinc\lib\win\ -lboinc_api -lboinc -lboinc_opencl -lOpenCL -D_WIN64 -DWIN64 -D_WIN32 -DWIN32 -DWANTED_CACTUS_HEIGHT=21
  20. dir
  21. - uses: actions/upload-artifact@v2
  22. with:
  23. name: kaktwoos-ocl-win
  24. path: .\kakt*.exe
  25. linux_opencl:
  26. name: opencl/release/linux
  27. runs-on: [ubuntu-latest]
  28. container: nvidia/opencl:devel-ubuntu16.04
  29. steps:
  30. - uses: actions/checkout@v2
  31. - name: build
  32. run: |
  33. apt-get update && apt-get install -y \
  34. ocl-icd-opencl-dev g++ libc6-dev && \
  35. rm -rf /var/lib/apt/lists/*
  36. g++ -w -m64 -O3 ./main-nv.c -o kaktwoos-ocl-nvidia -Iboinc/ -Lboinc/lib/lin -static-libgcc -static-libstdc++ -lboinc_api -lboinc -lboinc_opencl -pthread -Wl,-Bdynamic -lOpenCL -Wl,-dynamic-linker,/lib64/ld-linux-x86-64.so.2 -DWANTED_CACTUS_HEIGHT=21
  37. g++ -w -m64 -O3 ./main-amd.c -o kaktwoos-ocl-amd -Iboinc/ -Lboinc/lib/lin -static-libgcc -static-libstdc++ -lboinc_api -lboinc -lboinc_opencl -pthread -Wl,-Bdynamic -lOpenCL -Wl,-dynamic-linker,/lib64/ld-linux-x86-64.so.2 -DWANTED_CACTUS_HEIGHT=21
  38. g++ -w -m64 -O3 ./main-intel.c -o kaktwoos-ocl-intel -Iboinc/ -Lboinc/lib/lin -static-libgcc -static-libstdc++ -lboinc_api -lboinc -lboinc_opencl -pthread -Wl,-Bdynamic -lOpenCL -Wl,-dynamic-linker,/lib64/ld-linux-x86-64.so.2 -DWANTED_CACTUS_HEIGHT=21
  39. ls -la
  40. - uses: actions/upload-artifact@v2
  41. with:
  42. name: kaktwoos-ocl-lin
  43. path: ./kaktwoos-ocl*