Skip to content

Instantly share code, notes, and snippets.

@jimhester
Last active August 29, 2015 14:20
Show Gist options
  • Save jimhester/b7f05f50794c88e44b17 to your computer and use it in GitHub Desktop.
Save jimhester/b7f05f50794c88e44b17 to your computer and use it in GitHub Desktop.
Windows LDFLAGS error
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/aes.c -o src/aes.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/crc32.c -o src/crc32.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/digest.c -o src/digest.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/init.c -o src/init.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/md5.c -o src/md5.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/pmurhash.c -o src/pmurhash.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/raes.c -o src/raes.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/sha1.c -o src/sha1.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/sha256.c -o src/sha256.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/sha2.c -o src/sha2.o
gcc -std=gnu99 -I/usr/share/R/include -DNDEBUG -fpic -g -O0 -fprofile-arcs -ftest-coverage -c src/xxhash.c -o src/xxhash.o
gcc -std=gnu99 -shared -L/usr/lib/R/lib --coverage -o src/aes.so src/aes.o src/crc32.o src/digest.o src/init.o src/md5.o src/pmurhash.o src/raes.o src/sha1.o src/sha256.o src/sha2.o src/xxhash.o -L/usr/lib/R/lib -lR
SET R_MAKEVARS_USER=test.mk
"C:/PROGRA~1/R/R-32~1.0/bin/x64/R" CMD SHLIB src\*c
R_MAKEVARS_USER=test.mk R CMD SHLIB src/*c
CFLAGS = -g -O0 -fprofile-arcs -ftest-coverage
LDFLAGS = --coverage
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/aes.c -o src/aes.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/crc32.c -o src/crc32.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/digest.c -o src/digest.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/init.c -o src/init.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/md5.c -o src/md5.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/pmurhash.c -o src/pmurhash.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/raes.c -o src/raes.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/sha1.c -o src/sha1.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/sha2.c -o src/sha2.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/sha256.c -o src/sha256.o
gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -g -O0 -fprofile-arcs -ftest-coverage -c src/xxhash.c -o src/xxhash.o
gcc -m64 -shared -s -static-libgcc -o src/aes.dll tmp.def src/aes.o src/crc32.o src/digest.o src/init.o src/md5.o src/pmurhash.o src/raes.o src/sha1.o src/sha2.o src/sha256.o src/xxhash.o -Ld:/RCompile/r-compiling/local/local320/lib/x64 -Ld:/RCompile/r-xompiling/local/local320/lib -LC:/PROGRA~1/R/R-32~1.0/bin/x64 -lR
src/aes.o: In function `_GLOBAL__sub_I_65535_0_do_init':
E:\digest/src/aes.c:764: undefined reference to `__gcov_init'
src/aes.o:aes.c:(.data+0xa8): undefined reference to `__gcov_merge_add'
src/crc32.o: In function `_GLOBAL__sub_I_65535_0_digest_crc32':
E:\digest/src/crc32.c:277: undefined reference to `__gcov_init'
src/crc32.o:crc32.c:(.data+0x88): undefined reference to `__gcov_merge_add'
src/digest.o: In function `_GLOBAL__sub_I_65535_0_digest':
E:\digest/src/digest.c:452: undefined reference to `__gcov_init'
src/digest.o:digest.c:(.data+0x68): undefined reference to `__gcov_merge_add'
src/init.o: In function `_GLOBAL__sub_I_65535_0_R_init_digest':
E:\digest/src/init.c:43: undefined reference to `__gcov_init'
src/init.o:init.c:(.data+0x88): undefined reference to `__gcov_merge_add'
src/md5.o: In function `_GLOBAL__sub_I_65535_0_md5_starts':
E:\digest/src/md5.c:231: undefined reference to `__gcov_init'
src/md5.o:md5.c:(.data+0xc8): undefined reference to `__gcov_merge_add'
src/pmurhash.o: In function `_GLOBAL__sub_I_65535_0_PMurHash32_Process':
E:\digest/src/pmurhash.c:338: undefined reference to `__gcov_init'
src/pmurhash.o:pmurhash.c:(.data+0x88): undefined reference to `__gcov_merge_add'
src/raes.o: In function `_GLOBAL__sub_I_65535_0_encrypt':
E:\digest/src/raes.c:100: undefined reference to `__gcov_init'
src/raes.o:raes.c:(.data+0xa8): undefined reference to `__gcov_merge_add'
src/sha1.o: In function `_GLOBAL__sub_I_65535_0_sha1_starts':
E:\digest/src/sha1.c:266: undefined reference to `__gcov_init'
src/sha1.o:sha1.c:(.data+0xc8): undefined reference to `__gcov_merge_add'
src/sha2.o: In function `_GLOBAL__sub_I_65535_0_SHA256_Init':
E:\digest/src/sha2.c:1066: undefined reference to `__gcov_init'
src/sha2.o:sha2.c:(.data+0x148): undefined reference to `__gcov_merge_add'
src/sha256.o: In function `_GLOBAL__sub_I_65535_0_sha256_starts':
E:\digest/src/sha256.c:261: undefined reference to `__gcov_init'
src/sha256.o:sha256.c:(.data+0xc8): undefined reference to `__gcov_merge_add'
src/xxhash.o: In function `_GLOBAL__sub_I_65535_0_XXH32':
E:\digest/src/xxhash.c:926: undefined reference to `__gcov_init'
src/xxhash.o:xxhash.c:(.data+0x108): undefined reference to `__gcov_merge_add'
collect2: ld returned 1 exit status
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment