daily pastebin goal
23%
SHARE
TWEET

Untitled

a guest May 5th, 2012 31 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. /*
  3.  * helloworld_gmp.c
  4.  
  5. $ gcc -lgmp helloworld_gmp.c
  6. /tmp/ccH3D1lt.o: In function `main':
  7. helloworld_gmp.c:(.text+0x17): undefined reference to `__gmpz_init'
  8. collect2: ld returned 1 exit status
  9.  
  10. $ cat /etc/lsb-release
  11. DISTRIB_ID=Ubuntu
  12. DISTRIB_RELEASE=11.10
  13. DISTRIB_CODENAME=oneiric
  14. DISTRIB_DESCRIPTION="Ubuntu 11.10"
  15.  
  16. $ uname -a
  17. Linux lathe 3.2.15-030215-generic #201204131303 SMP Fri Apr 13 17:04:51 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux
  18.  
  19. $ ls -la /usr/include/gmp*
  20. -rw-r--r-- 1 root root   2198 2011-04-21 02:53 /usr/include/gmp.h
  21. -rw-r--r-- 1 root root  86222 2011-04-21 02:53 /usr/include/gmp-x86_64.h
  22. -rw-r--r-- 1 root root 114646 2011-04-21 02:58 /usr/include/gmpxx.h
  23.  
  24. $ ls -la /usr/lib/*gmp*
  25. -rw-r--r-- 2 root root 1213422 2011-04-21 03:04 /usr/lib/libgmp.a
  26. -rw-r--r-- 1 root root     927 2011-04-21 02:58 /usr/lib/libgmp.la
  27. lrwxrwxrwx 1 root root      16 2012-02-01 03:51 /usr/lib/libgmp.so -> libgmp.so.10.0.1
  28. lrwxrwxrwx 1 root root      16 2012-02-01 03:48 /usr/lib/libgmp.so.10 -> libgmp.so.10.0.1
  29. -rw-r--r-- 1 root root  475096 2011-04-21 03:04 /usr/lib/libgmp.so.10.0.1
  30. lrwxrwxrwx 1 root root      15 2011-04-21 02:37 /usr/lib/libgmp.so.3 -> libgmp.so.3.5.2
  31. -rw-r--r-- 1 root root  380736 2011-04-21 02:37 /usr/lib/libgmp.so.3.5.2
  32. -rw-r--r-- 1 root root   34660 2011-04-21 03:04 /usr/lib/libgmpxx.a
  33. -rw-r--r-- 1 root root     956 2011-04-21 02:58 /usr/lib/libgmpxx.la
  34. lrwxrwxrwx 1 root root      17 2012-02-01 03:51 /usr/lib/libgmpxx.so -> libgmpxx.so.4.2.1
  35. lrwxrwxrwx 1 root root      17 2012-02-01 03:51 /usr/lib/libgmpxx.so.4 -> libgmpxx.so.4.2.1
  36. -rw-r--r-- 1 root root   14616 2011-04-21 03:04 /usr/lib/libgmpxx.so.4.2.1
  37.  
  38. */
  39.  
  40.  
  41. #include <stdio.h>
  42. #include <stdlib.h>
  43.  
  44. #include <gmp.h>
  45.  
  46. int main(int argc, char **argv) {
  47.   mpz_t z;
  48.  
  49.   mpz_init(z);
  50. }
RAW Paste Data
Pastebin PRO WINTER Special!
Get 40% OFF Pastebin PRO accounts!
Top