Skip to content
Browse files

Append LIBS to the end of build command line

Since some versions of GCC requires libraries are appended to the
end of build command line. For instance, GCC in Ubuntu 12.04 (LTS)
requires it.
  • Loading branch information...
1 parent fa7461e commit 9915a77dc0cfa01f2a70e23f787e2062192503c8 @Constellation Constellation committed Nov 19, 2013
View
2 test/cuda/user/float/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o float_gpu.cubin float_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c float.c
+ gcc -o $(TARGET) $(CFLAGS) main.c float.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/fmadd/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o fmadd_gpu.cubin fmadd_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c fmadd.c
+ gcc -o $(TARGET) $(CFLAGS) main.c fmadd.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/fmmul/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o fmmul_gpu.cubin fmmul_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c fmmul.c
+ gcc -o $(TARGET) $(CFLAGS) main.c fmmul.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/idle/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o idle_gpu.cubin idle_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c idle.c
+ gcc -o $(TARGET) $(CFLAGS) main.c idle.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/loop/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o loop_gpu.cubin loop_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c loop.c
+ gcc -o $(TARGET) $(CFLAGS) main.c loop.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/loop_repeated/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o loop_gpu.cubin loop_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c loop_repeated.c
+ gcc -o $(TARGET) $(CFLAGS) main.c loop_repeated.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/madd/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o madd_gpu.cubin madd_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c madd.c
+ gcc -o $(TARGET) $(CFLAGS) main.c madd.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/madd_host/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o madd_gpu.cubin madd_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c madd_host.c
+ gcc -o $(TARGET) $(CFLAGS) main.c madd_host.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/madd_pinned/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o madd_gpu.cubin madd_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c madd_pinned.c
+ gcc -o $(TARGET) $(CFLAGS) main.c madd_pinned.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/madd_vmmap/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o madd_gpu.cubin madd_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c madd_vmmap.c
+ gcc -o $(TARGET) $(CFLAGS) main.c madd_vmmap.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/madd_vmmap_hybrid/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o madd_gpu.cubin madd_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c madd_vmmap_hybrid.c
+ gcc -o $(TARGET) $(CFLAGS) main.c madd_vmmap_hybrid.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/memcpy/Makefile
@@ -6,7 +6,7 @@ LIBS = -lucuda -lgdev
CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c memcpy.c
+ gcc -o $(TARGET) $(CFLAGS) main.c memcpy.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/memcpy_2step/Makefile
@@ -6,7 +6,7 @@ LIBS = -lucuda -lgdev
CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c memcpy_2step.c
+ gcc -o $(TARGET) $(CFLAGS) main.c memcpy_2step.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/memcpy_async/Makefile
@@ -6,7 +6,7 @@ LIBS = -lucuda -lgdev
CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c memcpy_async.c
+ gcc -o $(TARGET) $(CFLAGS) main.c memcpy_async.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/memcpy_pinned/Makefile
@@ -6,7 +6,7 @@ LIBS = -lucuda -lgdev
CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c memcpy_pinned.c
+ gcc -o $(TARGET) $(CFLAGS) main.c memcpy_pinned.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/memcpy_swap/Makefile
@@ -6,7 +6,7 @@ LIBS = -lucuda -lgdev
CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c
+ gcc -o $(TARGET) $(CFLAGS) main.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/mmul/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o mmul_gpu.cubin mmul_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c mmul.c
+ gcc -o $(TARGET) $(CFLAGS) main.c mmul.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/mmul_host/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o mmul_gpu.cubin mmul_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c mmul_host.c
+ gcc -o $(TARGET) $(CFLAGS) main.c mmul_host.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/mmul_vmmap/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o mmul_gpu.cubin mmul_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c mmul_vmmap.c
+ gcc -o $(TARGET) $(CFLAGS) main.c mmul_vmmap.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/mmul_vmmap_hybrid/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o mmul_gpu.cubin mmul_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c mmul_vmmap_hybrid.c
+ gcc -o $(TARGET) $(CFLAGS) main.c mmul_vmmap_hybrid.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/overload_mem/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o loop_gpu.cubin loop_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c
+ gcc -o $(TARGET) $(CFLAGS) main.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/shm/Makefile
@@ -6,7 +6,7 @@ LIBS = -lucuda -lgdev
CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c shm.c
+ gcc -o $(TARGET) $(CFLAGS) main.c shm.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~
View
2 test/cuda/user/vmmap/Makefile
@@ -7,7 +7,7 @@ CFLAGS = -L /usr/local/gdev/lib64 -I /usr/local/gdev/include
all:
$(NVCC) -o madd_gpu.cubin madd_gpu.cu
- gcc -o $(TARGET) $(CFLAGS) $(LIBS) main.c vmmap.c
+ gcc -o $(TARGET) $(CFLAGS) main.c vmmap.c $(LIBS)
clean:
rm -f $(TARGET) *.cubin ./*~

0 comments on commit 9915a77

Please sign in to comment.
Something went wrong with that request. Please try again.