Note that there are some explanatory texts on larger screens.

plurals
  1. POMakefile variable substitution sometimes ignored
    text
    copied!<p>Compiling a CUDA enabled version of aircrack-ng that hasn't been bug-fixed in a while so needed a bit of patching to get <em>most</em> of the way there. </p> <p>Basically, the make cannot find the relevant compiler (<code>nvcc</code>) for this one section of code;</p> <p><em>Relevent Makefile section</em></p> <pre><code>ifeq ($(CUDA), true) CFLAGS += -DCUDA_ENABLED NVCC := $(CUDA_BIN)/nvcc INCLUDES += -I. -I$(CUDA_INSTALL_PATH)/include COMMONFLAGS += $(INCLUDES) -DUNIX NVCCFLAGS += --compiler-options -fno-strict-aliasing --host-compilation=C $(COMMONFLAGS) # Change this only if you have COMPUTE &gt; 1.0 NVCCFLAGS += -maxrregcount 12 # Enable this for extra compiler and as output #NVCCFLAGS += --ptxas-options "-v" --verbose LIBSSL += -L$(CUDA_INSTALL_PATH)/lib -L$(CUDA_INSTALL_PATH)/lib64 -lcuda -lcudart %.o : %.cu $(NVCC) $(NVCCFLAGS) $(SMVERSIONFLAGS) -o $@ -c $&lt; endif </code></pre> <p><em>Relevant Make output</em></p> <pre><code>/nvcc --compiler-options -fno-strict-aliasing --host-compilation=C -I. -I/include -DUNIX -maxrregcount 12 -o cudacrypto.o -c cudacrypto.cu make[1]: /nvcc: Command not found make[1]: *** [cudacrypto.o] Error 127 make[1]: Leaving directory `/home/bolster/src/aircrack-ng-cuda/src' make: *** [install] Error 2 </code></pre> <p>As you can see it looks like make is dropping the environment variables 'CUDA_BIN'.</p> <p><em>Output of <code>echo $CUDA_BIN</code></em></p> <pre><code>/usr/local/cuda/bin </code></pre> <p><em>Output of <code>which nvcc</code></em></p> <pre><code>/usr/local/cuda/bin/nvcc </code></pre> <p>I am not a make-guru by any stretch, so if I'm doing something patently obviously wrong, forgive me.</p> <p>After trying hard coding the nvcc flag with the full path, that section compiles, but when it comes to a crypto section (involving libssl) it cannot find the necessary libraries, and in a similar fashion as above isn't replacing 'CUDA_INSTALL_PATH', even though it is in the environment, which indicates to be that something weird is going on.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload