![]() |
compiling mprime on linux
Is there a readme or guide that describes how to compile 26.5 from source?
|
Source: [url]ftp://mersenne.org/gimps/source265.zip[/url]
For me it errors out on the make step. [code]$ pwd /dev/shm/linux64 $ cd linux64 $ make [ ! -e ../security.h ] && touch ../security.h || true [ ! -e ../security.c ] && touch ../security.c || true [ ! -e ../secure5.c ] && touch ../secure5.c || true gcc -I.. -I../gwnum -DX86_64 -O2 -Wno-unused-result -c prime.c gcc -I.. -I../gwnum -DX86_64 -O2 -Wno-unused-result -c menu.c gcc -Wl,-M -o mprime prime.o menu.o factor64.o ../gwnum/gwnum.a ../gwnum/gwnum.ld -lm -lpthread -Wl,-Bstatic -lcurl -lrt -lssl -lcrypto -ldl -lz -lstdc++ -Wl,-Bdynamic -ldl gcc: ../gwnum/gwnum.a: No such file or directory make: *** [mprime] Error 1[/code] Tried moving that file to the specified dir but no joy. [code]$ cp ../gwnum/linux64/gwnum.a ../gwnum/ $ make <<cut>> menu.o: In function `torture': menu.c:(.text+0x2318): undefined reference to `CPU_HYPERTHREADS' menu.c:(.text+0x235c): undefined reference to `CPU_HYPERTHREADS' menu.c:(.text+0x23f2): undefined reference to `CPU_FLAGS' menu.c:(.text+0x2423): undefined reference to `CPU_FLAGS' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlopen.o): In function `dlopen': (.text+0x5): undefined reference to `__dlopen' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlclose.o): In function `dlclose': (.text+0x1): undefined reference to `__dlclose' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlsym.o): In function `dlsym': (.text+0x5): undefined reference to `__dlsym' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlerror.o): In function `dlerror': (.text+0x1): undefined reference to `__dlerror' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dladdr.o): In function `dladdr': (.text+0x1): undefined reference to `__dladdr' collect2: ld returned 1 exit status make: *** [mprime] Error 1[/code] Thoughts and suggestions are welcomed! |
cd gwnum
make -f make64 cd ../linux64 make |
If you get errors linking to cURL. Try downloading the libcurl sources and follow the instructions in ../linux/makefile for making a libcurl that doesn't drag in a whole bunch of junk
|
Thanks for the info. I rebuilt curl as per the instructions, then:
[code]$ bsdtar -xf source265.zip $ cd gwnum $ make -f make64 gcc -I.. -DX86_64 -O2 -c cpuid.c gcc -I.. -DX86_64 -O2 -c gwnum.c gcc -I.. -DX86_64 -O2 -c gwthread.c gcc -I.. -DX86_64 -O2 -c gwutil.c g++ -I.. -I../qd -DX86_64 -O2 -c gwdbldbl.cpp gcc -I.. -DX86_64 -O2 -c giants.c gcc -I.. -DX86_64 -O2 -c ecmstag1.c cp linux64/gwnum.a . ar -rs gwnum.a cpuid.o gwnum.o gwthread.o gwutil.o gwdbldbl.o giants.o ecmstag1.o $ cd ../linux64 $ make <<CUT>> .debug_weaknames *(.debug_weaknames .zdebug_weaknames) .debug_funcnames *(.debug_funcnames .zdebug_funcnames) .debug_typenames *(.debug_typenames .zdebug_typenames) .debug_varnames *(.debug_varnames .zdebug_varnames) .debug_pubtypes *(.debug_pubtypes .zdebug_pubtypes) .debug_ranges *(.debug_ranges .zdebug_ranges) .gnu.attributes *(.gnu.attributes) /DISCARD/ *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) OUTPUT(mprime elf64-x86-64) prime.o: In function `pnHttpServerCURL': prime.c:(.text+0x15e48): undefined reference to `curl_easy_init' prime.c:(.text+0x15e7d): undefined reference to `curl_easy_setopt' prime.c:(.text+0x15f1f): undefined reference to `curl_easy_setopt' prime.c:(.text+0x15f78): undefined reference to `curl_easy_setopt' prime.c:(.text+0x15f8a): undefined reference to `curl_easy_setopt' prime.c:(.text+0x15fa9): undefined reference to `curl_easy_setopt' prime.o:prime.c:(.text+0x15fba): more undefined references to `curl_easy_setopt' follow prime.o: In function `pnHttpServerCURL': prime.c:(.text+0x16040): undefined reference to `curl_easy_perform' prime.c:(.text+0x16078): undefined reference to `curl_easy_cleanup' prime.c:(.text+0x1609c): undefined reference to `curl_easy_cleanup' prime.c:(.text+0x16126): undefined reference to `curl_easy_setopt' prime.c:(.text+0x1613d): undefined reference to `curl_easy_setopt' prime.c:(.text+0x16177): undefined reference to `curl_easy_setopt' prime.c:(.text+0x1618b): undefined reference to `curl_easy_setopt' prime.o: In function `LoadPrimenet': prime.c:(.text+0xec7a): undefined reference to `curl_global_init' collect2: ld returned 1 exit status make: *** [mprime] Error 1[/code] The complete output of make is on pastebin [url=http://pastebin.com/TLVidj4J]here[/url]. Ideas? Note, if I use curl that comes with my distro, I get a different set of errors on the make step: [code]$ make <<CUT>> /libcrypto.a(cms_io.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(cms_dd.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(cms_cd.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(bn_nist.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(ecp_smpl.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(bio_ndef.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(asn_mime.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(bn_kron.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(bn_sqrt.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(bio_b64.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(bio_asn1.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlopen.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlclose.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlsym.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlerror.o) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dladdr.o) .comment 0x0000000000000027 0x11 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libz.a(deflate.o) 0x12 (size before relaxing) .comment 0x0000000000000000 0x12 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libz.a(inflate.o) .comment 0x0000000000000000 0x12 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libz.a(inftrees.o) .comment 0x0000000000000000 0x12 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libz.a(trees.o) .comment 0x0000000000000000 0x12 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libz.a(zutil.o) .comment 0x0000000000000000 0x12 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libz.a(adler32.o) .comment 0x0000000000000000 0x12 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libz.a(crc32.o) .comment 0x0000000000000000 0x12 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libz.a(inffast.o) .comment 0x0000000000000000 0x28 /usr/lib/libc_nonshared.a(elf-init.oS) .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/crtend.o .comment 0x0000000000000000 0x28 /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/crtn.o .debug *(.debug) .line *(.line) .debug_srcinfo *(.debug_srcinfo .zdebug_srcinfo) .debug_sfnames *(.debug_sfnames .zdebug_sfnames) .debug_aranges *(.debug_aranges .zdebug_aranges) .debug_pubnames *(.debug_pubnames .zdebug_pubnames) .debug_info *(.debug_info .gnu.linkonce.wi.* .zdebug_info) .debug_abbrev *(.debug_abbrev .zdebug_abbrev) .debug_line *(.debug_line .zdebug_line) .debug_frame *(.debug_frame .zdebug_frame) .debug_str *(.debug_str .zdebug_str) .debug_loc *(.debug_loc .zdebug_loc) .debug_macinfo *(.debug_macinfo .zdebug_macinfo) .debug_weaknames *(.debug_weaknames .zdebug_weaknames) .debug_funcnames *(.debug_funcnames .zdebug_funcnames) .debug_typenames *(.debug_typenames .zdebug_typenames) .debug_varnames *(.debug_varnames .zdebug_varnames) .debug_pubtypes *(.debug_pubtypes .zdebug_pubtypes) .debug_ranges *(.debug_ranges .zdebug_ranges) .gnu.attributes *(.gnu.attributes) /DISCARD/ *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) OUTPUT(mprime elf64-x86-64) /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_globallookup': (.text+0x21): warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlopen.o): In function `dlopen': (.text+0x5): undefined reference to `__dlopen' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlclose.o): In function `dlclose': (.text+0x1): undefined reference to `__dlclose' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlsym.o): In function `dlsym': (.text+0x5): undefined reference to `__dlsym' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dlerror.o): In function `dlerror': (.text+0x1): undefined reference to `__dlerror' /usr/lib/gcc/x86_64-unknown-linux-gnu/4.5.2/../../../../lib/libdl.a(dladdr.o): In function `dladdr': (.text+0x1): undefined reference to `__dladdr' collect2: ld returned 1 exit status make: *** [mprime] Error 1[/code] |
Did you do a "make install" of libcurl?
You'll probably need help from a Linux expert - I'm definitely not one. |
Is it possible to build mprime using the system package(s) for libcurl ?
|
All times are UTC. The time now is 10:59. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.