Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't build CUDA opcodes on WSL Ubuntu "jammy" #1711

Closed
znmeb opened this issue May 8, 2023 · 3 comments
Closed

Can't build CUDA opcodes on WSL Ubuntu "jammy" #1711

znmeb opened this issue May 8, 2023 · 3 comments
Assignees

Comments

@znmeb
Copy link

znmeb commented May 8, 2023

For some reason, cmake is throwing an error when I try to build from source on a system with CUDA. The machine is Windows 11 Windows Subsystem for Linux Ubuntu "jammy". Here's the log:


cd $SYNTH_PROJECTS
export PATH=$PATH:/usr/local/bin/cuda

echo "Downloading csound source"
Downloading csound source
rm -fr csound*
echo "CSOUND_VERSION=$CSOUND_VERSION"
CSOUND_VERSION=6.18.1
git clone --recursive --branch=$CSOUND_VERSION https://github.com/csound/csound.git
Cloning into 'csound'...
Note: switching to 'a1580f9cdf331c35dceb486f4231871ce0b00266'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

Submodule 'vcpkg' (https://github.com/Microsoft/vcpkg.git) registered for path 'vcpkg'
Cloning into '/home/znmeb/Projects/AlgoCompSynth-One/WSL-jammy/Projects/csound/vcpkg'...
Submodule path 'vcpkg': checked out '97f26935db51139372ef252e67e308fe76933500'

echo "Configuring CSound"
Configuring CSound
rm -fr cs6make
mkdir cs6make
pushd cs6make
~/Projects/AlgoCompSynth-One/WSL-jammy/Projects/cs6make ~/Projects/AlgoCompSynth-One/WSL-jammy/Projects

  export CPATH=/usr/include/lame:/usr/include/pulse:$CPATH
  cmake \
    -Wno-dev \
    -DBUILD_CUDA_OPCODES=ON \
    -DBUILD_STATIC_LIBRARY=ON \
    -DBUILD_JAVA_INTERFACE=OFF \
    -DPULSEAUDIO_HEADER="/usr/include/pulse/simple.h" \
    ../csound
-- VCPKG_TARGET_TRIPLET: 
-- CMAKE_TOOLCHAIN_FILE: 
-- The C compiler identification is GNU 11.3.0
-- The CXX compiler identification is GNU 11.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Csound directory: /home/znmeb/Projects/AlgoCompSynth-One/WSL-jammy/Projects/csound
-- Csound version: 6.18.1
-- CMake module path: /home/znmeb/Projects/AlgoCompSynth-One/WSL-jammy/Projects/csound/cmake/Modules/
-- Performing Test HAS_TREE_VECTORIZE
-- Performing Test HAS_TREE_VECTORIZE - Success
-- Performing Test HAS_CXX_TREE_VECTORIZE
-- Performing Test HAS_CXX_TREE_VECTORIZE - Success
-- Performing Test HAS_FAST_MATH
-- Performing Test HAS_FAST_MATH - Success
-- Performing Test HAS_CXX_FAST_MATH
-- Performing Test HAS_CXX_FAST_MATH - Success
-- Performing Test HAS_FPMATH_SSE
-- Performing Test HAS_FPMATH_SSE - Success
-- Performing Test HAS_CXX_FPMATH_SSE
-- Performing Test HAS_CXX_FPMATH_SSE - Success
-- Performing Test HAS_SSE2
-- Performing Test HAS_SSE2 - Success
-- Performing Test HAS_CXX_SSE2
-- Performing Test HAS_CXX_SSE2 - Success
-- Performing Test HAS_OMIT_FRAME_POINTER
-- Performing Test HAS_OMIT_FRAME_POINTER - Success
-- Performing Test HAS_CXX_OMIT_FRAME_POINTER
-- Performing Test HAS_CXX_OMIT_FRAME_POINTER - Success
-- Not using Custom.cmake file.
-- LIBRARY INSTALL DIR: /usr/local/lib
-- Building with 64-bit floats
-- Performing Test HAS_VISIBILITY_HIDDEN
-- Performing Test HAS_VISIBILITY_HIDDEN - Success
-- Performing Test HAS_CXX_VISIBILITY_HIDDEN
-- Performing Test HAS_CXX_VISIBILITY_HIDDEN - Success
-- Performing Test HAS_GNU99
-- Performing Test HAS_GNU99 - Success
-- LINUX operating system found
-- default plugin dir set to /usr/local/lib/csound/plugins64-6.0
-- BUILD_BIN_DIR set to /home/znmeb/Projects/AlgoCompSynth-One/WSL-jammy/Projects/cs6make.
-- BUILD_LIB_DIR set to /home/znmeb/Projects/AlgoCompSynth-One/WSL-jammy/Projects/cs6make.
-- BUILD_PLUGINS_DIR set to /home/znmeb/Projects/AlgoCompSynth-One/WSL-jammy/Projects/cs6make.
-- Performing Test HAVE_SF_FORMAT_MPEG
-- Performing Test HAVE_SF_FORMAT_MPEG - Failed
-- HAVE_SF_FORMAT_MPEG="", so disabling USE_MP3
-- USE_MP3 is disabled.
-- NOT Using libsndfile MP3 support
-- Found CURL: /usr/lib/x86_64-linux-gnu/libcurl.so (found version "7.81.0")  
-- Could NOT find Java (missing: Java_JAVAC_EXECUTABLE Java_JAVADOC_EXECUTABLE) (found version "11.0.18")
-- Could NOT find JNI (missing: JAVA_INCLUDE_PATH JAVA_INCLUDE_PATH2 AWT) 
-- Performing Test HAVE_ATOMIC_BUILTIN_NOLIB
-- Performing Test HAVE_ATOMIC_BUILTIN_NOLIB - Success
-- Using atomic builtins.
-- Looking for libintl.h
-- Looking for libintl.h - found
-- Found Gettext: /usr/bin/msgmerge (found version "0.21") 
-- Looking for lrint
-- Looking for lrint - found
-- Looking for unistd.h
-- Looking for unistd.h - found
-- Looking for io.h
-- Looking for io.h - not found
-- Looking for fcntl.h
-- Looking for fcntl.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for sys/time.h
-- Looking for sys/time.h - found
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for termios.h
-- Looking for termios.h - found
-- Looking for values.h
-- Looking for values.h - found
-- Looking for winsock.h
-- Looking for winsock.h - not found
-- Looking for sys/socket.h
-- Looking for sys/socket.h - found
-- Looking for dirent.h
-- Looking for dirent.h - found
-- Looking for inttypes.h
-- Looking for inttypes.h - found
-- Looking for execinfo.h
-- Looking for execinfo.h - found
-- USE_LRINT is enabled.
-- Found FLEX: /usr/bin/flex (found version "2.6.4") 
-- Found BISON: /usr/bin/bison (found version "3.8.2") 
-- Looking for pthread_spin_lock
-- Looking for pthread_spin_lock - found
-- Looking for pthread_barrier_init
-- Looking for pthread_barrier_init - found
-- Found Git: /usr/bin/git (found version "2.34.1") 
-- GIT: /usr/bin/git
-- HASH: a1580f9cdf331c35dceb486f4231871ce0b00266
-- Not building with new parser debugging.
-- Building with multicore support.
-- USE_GETTEXT is enabled.
-- Using GNU gettext.
-- Setting textdomain to /usr/local/share/locale.
-- Building on Linux.
--   ADDING LIBRT LIBRARY: /usr/lib/x86_64-linux-gnu/librt.a.
-- Looking for strlcat
-- Looking for strlcat - not found
-- Looking for strtok_r
-- Looking for strtok_r - found
-- Looking for strtod_l
-- Looking for strtod_l - found
-- Looking for sprintf_l
-- Looking for sprintf_l - not found
-- Looking for _strtok_r
-- Looking for _strtok_r - not found
-- Looking for _strtod_l
-- Looking for _strtod_l - not found
-- Looking for _sprintf_l
-- Looking for _sprintf_l - not found
-- ## Building Plugin Opcodes ##
-- Performing Test COMPILER_SUPPORTS_CXX11
-- Performing Test COMPILER_SUPPORTS_CXX11 - Success
-- Performing Test COMPILER_SUPPORTS_CXX0X
-- Performing Test COMPILER_SUPPORTS_CXX0X - Success
-- BUILD_DSSI_OPCODES is enabled.
-- Looking for ladspa.h
-- Looking for ladspa.h - found
-- Found liblo: /usr/lib/x86_64-linux-gnu/liblo.so
-- 
-- ## REALTIME AUDIO AND MIDI ##
-- Looking for alsa/asoundlib.h
-- Looking for alsa/asoundlib.h - found
-- Found Portaudio: /usr/lib/x86_64-linux-gnu/libportaudio.so
-- Looking for jack/jack.h
-- Looking for jack/jack.h - found
-- USE_ALSA is enabled.
-- USE_PULSEAUDIO is enabled.
-- Building rtpa module.
-- USE_JACK is enabled.
-- Building C++ interface library.
-- Found SWIG: /usr/bin/swig4.0 (found suitable version "4.0.2", minimum required is "2.0")  
-- Could NOT find JNI (missing: JAVA_INCLUDE_PATH JAVA_INCLUDE_PATH2 AWT) 
-- Could NOT find Java (missing: Java_JAVAC_EXECUTABLE Java_JAVADOC_EXECUTABLE) (found version "11.0.18")
-- BUILD_JAVA_INTERFACE is disabled.
-- BUILD_LUA_INTERFACE is enabled.
-- PYTHON3 MODULE INSTALL DIR: /usr/local/lib/python3.10/dist-packages
-- SWIG_USE_FILE: /usr/local/share/cmake-3.25/Modules/UseSWIG.cmake
-- BUILD_CSBEATS is enabled.
-- Not building belacsound program.
-- CUNIT_LIBRARY="CUNIT_LIBRARY-NOTFOUND", so disabling BUILD_TESTS
-- BUILD_TESTS is disabled.
-- Found Doxygen: /usr/bin/doxygen (found version "1.9.1") found components: doxygen dot 
-- Configuring done
-- Generating done
CMake Warning:
  Manually-specified variables were not used by the project:

    BUILD_CUDA_OPCODES


-- Build files have been written to: /home/znmeb/Projects/AlgoCompSynth-One/WSL-jammy/Projects/cs6make
  exit
18.70user 5.99system 0:36.91elapsed 66%CPU (0avgtext+0avgdata 86392maxresident)k
0inputs+579344outputs (17major+364158minor)pagefaults 0swaps

This used to work. Is there a new syntax for specifying CUDA builds, or is it trying to automatically locate CUDA and not finding it.

@kunstmusik
Copy link
Member

(Requesting @vlazzarini to evaluate.)

@znmeb
Copy link
Author

znmeb commented Jan 2, 2024

This is probably a bogus issue - the Csound source was re-organized between the time when the script was written and the build worked and when I opened the issue. The CUDA code is now in a different repository; I haven't had a chance to revise the build script. You can close this if you want to.

@znmeb znmeb closed this as completed Jan 2, 2024
@kunstmusik
Copy link
Member

Thanks @znmeb for following up, issue is now closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants