Talk:SDCard Testing: Difference between revisions
Jump to navigation
Jump to search
(Created page with 'Flashbench does not compile on 12.04 64bit: <blockquote> flashbench/dev.c:35: undefined reference to `clock_gettime' collect2: ld returned 1 exit status </blockquote> To fix th…') |
No edit summary |
||
Line 1: | Line 1: | ||
Flashbench does not compile on 12.04 64bit: |
Flashbench does not compile on Ubuntu 12.04 64bit: |
||
⚫ | |||
<blockquote> |
|||
⚫ | |||
⚫ | |||
⚫ | |||
</blockquote> |
|||
To fix this, the flag -lrt has to go at the end of the linking line of flashbench, ie |
To fix this, the flag -lrt has to go at the end of the linking line of flashbench, ie |
||
⚫ | |||
<blockquote> |
|||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
+++ b/Makefile |
|||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
@@ -8,7 +8,7 @@ dev.o: dev.c dev.h |
|||
vm.o: vm.c vm.h dev.h |
|||
flashbench.o: flashbench.c vm.h dev.h |
|||
flashbench |
-flashbench: flashbench.o dev.o vm.o |
||
+flashbench: flashbench.o dev.o vm.o -lrt |
|||
+flashbench: flashbench.o dev.o vm.o -lrt |
|||
⚫ | |||
⚫ | |||
</blockquote> |
Latest revision as of 08:31, 15 May 2012
Flashbench does not compile on Ubuntu 12.04 64bit:
flashbench/dev.c:35: undefined reference to `clock_gettime' collect2: ld returned 1 exit status
To fix this, the flag -lrt has to go at the end of the linking line of flashbench, ie
diff --git a/Makefile b/Makefile index 8fbd119..4c04f5e 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ CC := gcc -CFLAGS := -O2 -Wall -Wextra -Wno-missing-field-initializers -Wno-unused-paramet -LDFLAGS := -lrt +CFLAGS := -O2 -Wall -Wextra -Wno-missing-field-initializers -Wno-unused-paramet +LDFLAGS := all: flashbench erase @@ -8,7 +8,7 @@ dev.o: dev.c dev.h vm.o: vm.c vm.h dev.h flashbench.o: flashbench.c vm.h dev.h -flashbench: flashbench.o dev.o vm.o +flashbench: flashbench.o dev.o vm.o -lrt erase: erase.o