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

nvcc fatal : Unknown option 'pthread' !!!help!!!! #36

Open
Demalll opened this issue Sep 2, 2023 · 2 comments
Open

nvcc fatal : Unknown option 'pthread' !!!help!!!! #36

Demalll opened this issue Sep 2, 2023 · 2 comments

Comments

@Demalll
Copy link

Demalll commented Sep 2, 2023

nvcc fatal : Unknown option 'pthread'

error
~/NewDisk/CARLsim5/projects/hello_world$ sudo make
/bin/sh: 1: [: -ge: unexpected operator
/bin/sh: 1: [: -ge: unexpected operator
/usr/local/cuda/bin/nvcc -I/home/demal/CARL/include -L/home/demal/CARL/lib -pthread -Wno-deprecated-gpu-targets src/main_hello_world.cpp -o hello_world -lcarlsim -lcurand
nvcc fatal : Unknown option 'pthread'
Makefile:90: recipe for target 'hello_world' failed
make: *** [hello_world] Error 1

@Demalll
Copy link
Author

Demalll commented Sep 2, 2023

I have been changing various versions of cmake, but I do not know what version cuda9.0 and ubuntu16.04 should use, that is too many, keep trying seems inconvenient

@bainro
Copy link
Member

bainro commented Sep 28, 2023

I just got the cuda toolkit libraries to statically compile and uploaded the binary to this release page: https://github.com/UCI-CARL/CARLsim6/releases/tag/v6.1

I tested it on ubuntu 18, 20, and 22, so I don't know if 16 will work.

If that doesn't work, here's the commands I usually use to install:

mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=$HOME/carlsim6 -DCMAKE_BUILD_TYPE=Release .. 
make -j$(nproc) install

You could also try this cmake command instead:

cmake -DCMAKE_INSTALL_PREFIX=$HOME/carlsim6 -CARLSIM_NO_PTHREADS=OFF -DCMAKE_BUILD_TYPE=Release .. 

I would avoid using sudo if you can.

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

2 participants