Build fails on linux, no srandomdev()
M-a-r-k opened this issue · 2 comments
M-a-r-k commented
Building on Linux (x86-64) fails. It looks like srandomdev() doesn't exist on Linux?
make[2]: Entering directory '/home/mark/Work/v-usb/examples/drivertest/commandline'
gcc `libusb-config --cflags` -O -g -Wall -c opendevice.c
gcc `libusb-config --cflags` -O -g -Wall -c runtest.c
runtest.c: In function ‘main’:
runtest.c:114:9: warning: implicit declaration of function ‘srandomdev’ [-Wimplicit-function-declaration]
srandomdev();
^~~~~~~~~~
gcc -o runtest opendevice.o runtest.o `libusb-config --libs`
runtest.o: In function `main':
/home/mark/Work/v-usb/examples/drivertest/commandline/runtest.c:114: undefined reference to `srandomdev'
collect2: error: ld returned 1 exit status
Makefile:41: recipe for target 'runtest' failed
make[2]: *** [runtest] Error 1
make[2]: Leaving directory '/home/mark/Work/v-usb/examples/drivertest/commandline'
make[1]: Leaving directory '/home/mark/Work/v-usb'
starkjohann commented
You can simply remove this line if you want to run the tests on Linux.