Afficher la pageAnciennes révisionsLiens de retourHaut de page Cette page est en lecture seule. Vous pouvez afficher le texte source, mais ne pourrez pas le modifier. Contactez votre administrateur si vous pensez qu'il s'agit d'une erreur. Macaulay2 <note important>Depuis 2016, s'installe à partir de dépots comme http://www.math.uiuc.edu/Macaulay2/Downloads/GNU-Linux/Ubuntu/index.html</note> ====== 1.4 sur octopus ====== <code> rpm -ivh Macaulay2-1.4-1.common.rpm rpm -ivh Macaulay2-1.4-1.x86_64-Linux-ScientificLinux-5.5.rpm </code> Vérification simple: <code> [henry@octopus ~]$ M2 Macaulay2, version 1.4 with packages: ConwayPolynomials, Elimination, IntegralClosure, LLLBases, PrimaryDecomposition, ReesAlgebra, TangentCone i1 : 2+2 o1 = 4 </code> ====== installation des binaires ====== * sur calypso et t2000 * [[http://www.math.uiuc.edu/Macaulay2/Downloads/Solaris%20and%20SunOS/Macaulay2-0.9.2-sparc-SunOS-5.8.tar.gz|0.9.2]] * Utilisation: /usr/local/Macaulay2-0.9.2/bin/M2 ===== shrek ===== <code> shrek:~# dpkg -i Macaulay2-0.9.95-i386-Linux.deb Selecting previously deselected package macaulay2. (Reading database ... 22381 files and directories currently installed.) Unpacking macaulay2 (from Macaulay2-0.9.95-i386-Linux.deb) ... Setting up macaulay2 (0.9.95) ... Macaulay 2, version 0.9.95 with packages: Classic, Core, Elimination, IntegralClosure, LLLBases, Parsing, PrimaryDecomposition, SchurRings, TangentCone --dumping to /usr/lib/Macaulay2/Core/cache/Macaulay2-i686-data.tmp --success --moving: /usr/lib/Macaulay2/Core/cache/Macaulay2-i686-data.tmp -> /usr/lib/Macaulay2/Core/cache/Macaulay2-i686-data </code> ====== compilation version stable ====== * [[http://www.math.uiuc.edu/Macaulay2/|Home Page]] * compilé sur nemo, version 0.9.95 * en 32 bits pour commencer * options de compilation, voir scripts do_work.sh dans chaque répertoire * blas et lapack font partie de la Sun Perf Lib (--with-lapacklibs="-lsunperf") Les librairies nécessaires ^ nom ^ archive ^ installée dans ^ logs | | Singular-Factory | factory-3-0-2.tar.gz | /local/henry/logiciels/{lib,include} | /local/henry/factory/{WORK,MAKE_GFTABLES,INSTALL}.LOG | | Singular-Libfac | libfac-3-0-2.tar.gz | /local/henry/logiciels/{lib,include} | /local/henry/libfac/WORK.LOG | | gmp | 4.2.1 | /opt/csw/(lib,include) | | | gc | gc-7.0.tar.gz | /local/henry/logiciels/{lib,include} | /local/henry/gc-7.0/{WORK,CHECK}.LOG | | gdbm | 1.8.3 | /opt/csw/(lib,include) | | | ntl or Singular-ntl | ntl-5.4.1.tar.gz | /local/henry/logiciels/{lib,include} | /local/henry/ntl-5.4.1/src/{MAKE,INSTALL}.LOG | ====== compilation version stable (tout est recompilé) ====== * version 0.9.95 * en 32 bits * options de compilation, voir scripts do_work.sh dans chaque répertoire * blas et lapack font partie de la Sun Perf Lib (--with-lapacklibs="-lsunperf") Les librairies nécessaires ^ nom ^ archive ^ installée dans ^ logs | | Singular-Factory | factory-3-0-2.tar.gz | /local/henry/logiciels/{lib,include} | /local/henry/factory/{WORK,MAKE_GFTABLES,INSTALL}.LOG | | Singular-Libfac | libfac-3-0-2.tar.gz | /local/henry/logiciels/{lib,include} | /local/henry/libfac/WORK.LOG | | gmp | 4.2.2 | /local/henry/logiciels/{lib,include} | /local/henry/gmp-4.2.2/WORK.LOG | | gc | gc-7.0.tar.gz | /local/henry/logiciels/{lib,include} | /local/henry/gc-7.0/{WORK,CHECK}.LOG | | gdbm | 1.8.3 | /local/henry/logiciels/{lib,include} | /local/henry/gdbm-1.8.3/WORK.LOG | | readline | 5.2 | /local/henry/logiciels/{lib,include} | /local/henry/readline-5.2/WORK.LOG | | ncurses | 5.6 | /local/henry/logiciels/{lib,include} | /local/henry/ncurses-5.6/WORK.LOG | | ntl or Singular-ntl | ntl-5.4.1.tar.gz | /local/henry/logiciels/{lib,include} | /local/henry/ntl-5.4.1/src/{MAKE,INSTALL}.LOG | La compilation échoue: <code> ../c/scc1 -dep -J. ../../../Macaulay2/d/C.d ../../../Macaulay2/c/chk.c:2512: assertion failed ../../../Macaulay2/c/readfile.c:273: <- here make[2]: *** [C.dep] Error 1 make[2]: Leaving directory `/local/henry/M2/BUILD/Macaulay2/d' </code> ====== version svn ====== <code> nemo-dgrayson% svn co svn://macaulay2.math.uiuc.edu/Macaulay2/trunk/M2 ... Checked out revision 5981. nemo-dgrayson% cd M2 /home/dgrayson/M2 nemo-dgrayson% make + autoconf + rm -f include/config.h.in.stamp autoheader touch "include/config.h.in.stamp" --: The configure script in this directory has been prepared. --: To configure and build Macaulay 2: --: mkdir BUILD/normal cd BUILD/normal ../../configure --prefix=/usr/local make install --: --: To reconfigure and try again: --: cd BUILD/normal make reconfigure install --: --: To see all the options to "configure": --: ./configure --help --: </code> 1er problème: ne détecte pas la lib factory: <code> conftest.cpp:6: error: `SW_USE_NTL' undeclared (first use this function) </code> avec le code suivant: <code> #include <factoryconf.h> extern const char * libfac_version; int main () { extern const char factoryVersion[]; return SW_USE_NTL; return *factoryVersion; return *libfac_version; } </code> mais SW_USE_NTL n'est déclaré nulle part! (grep -r SW_USE_NTL *). On le supprime!\\ Voir les modifs sur le configure.ac <code> diff ../../configure.ac ../../configure.ac.ori 413c413 < do eval BUILD_$i=yes --- > do eval BUILD_$i=no 531,532c531,532 < test $BUILD_blas = yes && BUILTLIBS="-lsunperf $BUILTLIBS" < test $BUILD_lapack = yes && BUILTLIBS="-lsunperf $BUILTLIBS" --- > test $BUILD_blas = yes && BUILTLIBS="-lblas $BUILTLIBS" > test $BUILD_lapack = yes && BUILTLIBS="-llapack $BUILTLIBS" 551a552 > return SW_USE_NTL; 591,594c592,595 < #for i in $LIBLIST < #do eval t=\$BUILD_$i < # test "$t" = yes && LIBRARIES="$LIBRARIES $i" < #done --- > for i in $LIBLIST > do eval t=\$BUILD_$i > test "$t" = yes && LIBRARIES="$LIBRARIES $i" > done </code> et enfin, obligé de relinker /bin/sh sur /bin/bash (au lieu de /sbin/sh) sinon le make échoue immédiatement (grrr!) Nouvelle erreur: <code> ../../../../../Macaulay2/e/f4/../mem.hpp:123: error: `bzero' undeclared (first use this function) </code> pourquoi utiliser bzero() au lieu de memset()? [[http://www.opengroup.org/onlinepubs/000095399/functions/bzero.html|bzero]] On remplace: <code> nemo-henry% cp -rp Macaulay2/e/f4/../mem.hpp Macaulay2/e/f4/../mem.hpp.ori nemo-henry% diff Macaulay2/e/f4/../mem.hpp.ori Macaulay2/e/f4/../mem.hpp 7a8,9 > #define bzero(b,len) (memset((b), '\0', (len)), (void) 0) > </code> et toujours l'erreur: <code> ../../../../Macaulay2/e/ntl-interface.cpp:56: error: expected unqualified-id before numeric constant ../../../../Macaulay2/e/ntl-interface.cpp:56: error: expected `,' or `;' before numeric constant </code> corrigée par: <code> nemo-henry% diff Macaulay2/e/ntl-interface.cpp Macaulay2/e/ntl-interface.cpp.ori 56,58d55 < #if defined(__sun) && defined(__SVR4) < #undef GS < #endif </code> mais finalement, échoue sur: <code> ../c/scc1 -dep -J. ../../../../Macaulay2/d/C.d ../../../../Macaulay2/c/chk.c:2512: assertion failed ../../../../Macaulay2/c/readfile.c:274: <- here make[2]: *** [C.dep] Error 1 make[2]: Leaving directory `/local/henry/Macaulay2/subversion/M2/BUILD/normal/Macaulay2/d' restart: done make[1]: *** [all] Error 2 make[1]: Leaving directory `/local/henry/Macaulay2/subversion/M2/BUILD/normal/Macaulay2' make: *** [all] Error 2 make: Leaving directory `/local/henry/Macaulay2/subversion/M2/BUILD/normal' </code> En utilisant le debugger: <code> nemo-henry% dbx ../c/scc1 For information about new features see `help changes' To remove this message, put `dbxenv suppress_startup_message 7.5' in your .dbxrc Reading scc1 Reading ld.so.1 Reading libgc.so.1.0.3 Reading libm.so.2 Reading libc.so.1 Reading libpthread.so.1 Reading librt.so.1 Reading libdl.so.1 Reading libgcc_s.so.1 Reading libaio.so.1 Reading libmd5.so.1 (dbx) list (dbx) stop at 189 (2) stop at "scc1.c":189 (dbx) run -dep -J. ../../../../Macaulay2/d/C.d Running: scc1 -dep -J. ../../../../Macaulay2/d/C.d (process id 8680) t@1 (l@1) signal SEGV (no mapping at the fault address) in GC_SysVGetDataStart at 0xfef766dc 0xfef766dc: GC_SysVGetDataStart+0x0069: movb (%edx),%dl Current function is newnode1 23 char *p = malloc(n); (dbx) where current thread: t@1 [1] GC_SysVGetDataStart(0x1000, 0x8082ae4, 0xfefc0270, 0x620, 0xfef751b1), at 0xfef766dc [2] GC_register_data_segments(0xfef70d16, 0x14, 0x0, 0x0, 0x10, 0xfef8e128), at 0xfef7673e [3] GC_init_inner(0x0, 0xfefc0270, 0x1, 0xfef79e04, 0x80472b0, 0xfef93214), at 0xfef751b1 [4] GC_generic_malloc_many(0x28, 0x1, 0x98, 0xfef79c87), at 0xfef70d16 [5] GC_malloc(0x27, 0xfefca924, 0xfeffcc58, 0xfef6bf0b), at 0xfef79d4e [6] GC_debug_malloc(0x14, 0x807f178, 0x17, 0xfedb63c0), at 0xfef6bf2b =>[7] newnode1(len = 0, tag = 134509400), line 23 in "scc1.c" [8] UniqueStringN(s = 0x808288a "do", len = 0), line 233 in "dictionary.c" [9] UniqueString(s = 0x808288a "do"), line 18 in "type.c" [10] yyinit(), line 2837 in "grammar.c" [11] main(argc = 1, argv = 0x80475fc), line 188 in "scc1.c" </code> ====== Problèmes ====== ===== compilation de gmp ===== par défaut, le "make check" échoue pour gmp. * [[http://www.phfactor.net/wp/2006/06/09/gmp-421-on-solaris-10sparcv9-64-bit/|GMP 4.2.1 on Solaris 10/sparcv9, 64-bit]] * [[http://forums.oracle.com/forums/thread.jspa?messageID=2133670| Correct setting for LD_LIBRARY_PATH on 10gR2 Solaris 10 x86-64]] * [[http://www.sunfreeware.com/programlistintel10.html]] search gmp * [[http://ccnuma.anu.edu.au/~wpc/blog/programming/building-python.html|Building Python for Solaris 10 on SPARC]] ===== compilation de ntl ===== bien entendu, le configure ne prend pas tout en compte, du coup: <code> ./configure PREFIX=$HOME/logiciels/64 \ GMP_PREFIX=$HOME/logiciels/64 \ NTL_GMP_LIP=on NTL_STD_CXX=on NTL_NO_INIT_TRANS=on NTL_CXX_ONLY=on \ CC=c++ \ CFLAGS="-m64" \ LDFLAGS="-m64 -R/usr/sfw/lib/64 -R$HOME/logiciels/64/lib" \ </code> ===== compilation de factory ===== <code> LDFLAGS='-R$HOME/logiciels/64/lib -L$HOME/logiciels/64/lib' \ CFLAGS="-O0 -g -m64" \ CXXFLAGS="-g -O0 --no-rtti --no-exceptions -m64" \ LDFLAGS="-m64 -R/usr/sfw/lib/64 -R$HOME/logiciels/64/lib" \ ./configure --prefix=$HOME/logiciels/64 \ --enable-NTL \ --with-gmp=$HOME/logiciels/64/include,$HOME/logiciels/64/lib </code> ===== compilation de macaulay2 ===== cette erreur: <code> ** compiling ../../../Macaulay2/e/ntl_interface.cpp ../../../Macaulay2/e/ntl_interface.cpp:56: error: expected unqualified-id before numeric constant ../../../Macaulay2/e/ntl_interface.cpp:56: error: expected `,' or `;' before numeric constant make[2]: *** [ntl_interface.o] Error 1 </code> se résoud de la façon suivante: <code> nemo-henry% cp -rp ../Macaulay2/e/ntl_interface.cpp ../Macaulay2/e/ntl_interface.cpp.ori nemo-henry% diff ../Macaulay2/e/ntl_interface.cpp.ori ../Macaulay2/e/ntl_interface.cpp 55a56 > #undef GS </code> macaulay2.txt Dernière modification : 2017/08/25 09:56de 127.0.0.1