From 0e58a8f41e4632a74a32f09f3efd3eae927c427e Mon Sep 17 00:00:00 2001 From: Vitor Santos Costa Date: Thu, 18 Feb 2016 13:20:49 +0000 Subject: [PATCH] update README to refer to cmake, and to use MD format. Moved autoconf files out of the way so that people won't try using them. Removed INSTALL, as it just duplicates README.md. Maybe in the future. --- INSTALL | 136 ----------- README.TXT | 219 ------------------ README.md | 165 +++++++++++++ Makefile.in => autoconf/Makefile.in | 0 .../YapTermConfig.h.in | 0 config.guess => autoconf/config.guess | 0 config.h.in => autoconf/config.h.in | 0 config.sub => autoconf/config.sub | 0 configure => autoconf/configure | 0 configure.in => autoconf/configure.in | 0 install-sh => autoconf/install-sh | 0 11 files changed, 165 insertions(+), 355 deletions(-) delete mode 100644 INSTALL delete mode 100644 README.TXT create mode 100644 README.md rename Makefile.in => autoconf/Makefile.in (100%) rename YapTermConfig.h.in => autoconf/YapTermConfig.h.in (100%) rename config.guess => autoconf/config.guess (100%) rename config.h.in => autoconf/config.h.in (100%) rename config.sub => autoconf/config.sub (100%) rename configure => autoconf/configure (100%) rename configure.in => autoconf/configure.in (100%) rename install-sh => autoconf/install-sh (100%) diff --git a/INSTALL b/INSTALL deleted file mode 100644 index 08e27fcc0..000000000 --- a/INSTALL +++ /dev/null @@ -1,136 +0,0 @@ - - These are some basic instructions to compile and install YAP: - -1. How to compile Yap: - -To compile YAP just do: - - (1) mkdir arch - - (2) cd arch - - (3) ../configure ...options... - - (4) check the Makefile for any extensions or changes you want to make. - - (5) make - - (6) If the compilation succeeds, try ./yap - - (7) Happy? make install - -If you want corouting or CLP(QR), please do replace step 3 by - - (3') ../configure --enable-coroutining ...other options... - - -1.1 Where to install Yap - - Recent versions of Yap try to follow GNU conventions on where to -place software. - - o The main executable is placed at BINDIR. This executable is -actually a script that calls the Prolog engine, stored at LIBDIR. - - o LIBDIR contains the Prolog engine and a Prolog library. - - o INCLUDEDIR is used if you want to use Yap as a library. - -1.2 Which Yap - -Compiling Yap with the standard options give you a plain vanilla -Prolog. You can tune Yap to include some extra functionality - - o -DCOROUTINING=1 gives you delaying on goals, eg, freeze. - - o -DRATIONAL_TREES=1 includes support for rational trees. - - o -DDEPTH_LIMIT=1 allows depth limited evaluation, say for -implementing iterative deepening. - - o -DYAP_ARRAYS gives you two different styles of arrays. - - o -DANALYST and -DLOW_LEVEL_TRACER give you low level -debugging. ANALYST tells how your program uses the abstract machine -instructions. LOW_LEVEL_TRACER dumps the gory details of what your -program is doing. - -The next two options are good fun, but arguably not production -quality: - - o -DTABLING gives tabling in XSB style. - - o -DYAPOR gives or-parallelism in Muse style. If you add -DSBA to it -you will have the Sparse Binding Array instead of copying. If you add --DYAPOR_COW instead you will have the \alphaCOW model, that is, forking -instead of copying. - -1.3 Porting Yap - -The system has been mainly tested with GCC, but we have been able to -compile versions of Yap under lcc in Linux, Sun's cc compiler, IBM's -xlc, SGI's cc, Microsoft's Visual C++ 6.0 and HP's cc. - -1.3.1 Yap and GCC - -Yap has been developed to take advantage of GCC (but not to depend on -it). The major advantage of GCC is threaded code and register -reservation. - -YAP is set by default to compile with the best compilation flags we -know. Even so, a few specific options can be used depending on the -architecture: - -1.3.1.1 x86 - -The flag: - - YAP_EXTRAS= ... -DBP_FREE=1 - -tells us to use the %bp register (frame-pointer) as the emulator's -program counter. This seems to be stable and should become default -real soon now. - -1.3.1.2 Sparc/Solaris2 - -Use: - - YAP_EXTRAS= ... -mno-app-regs -DOPTIMISE_ALL_REGS_FOR_SPARC=1 - -and YAP will get two extra registers! This trick does not work on -SunOS 4 machines. - -1.3.1.3 Tuning GCC/Yap for your machine model - -Versions of GCC can be tweaked for different processors, eg, 486, -Pentium, PentiumPro, Ultrasparc, Supersparc. Unfortunately, some of -these tweaks do may make Yap run slower or not at all in other machines -with the same instruction set, so they cannot be made default. - -The best options also depends on the version of GCC you are using, and -it is a good idea to consult the GCC manual under the menus "Invoking -GCC"/"Submodel Options". We next describe a few: - -(a) GCC up to 2.7.*: - - o 486: - - YAP_EXTRAS= ... -m486 -DBP_FREE=1 - - to take advantage of 486 specific optimisations in GCC 2.7.*. - - o Pentium: - - YAP_EXTRAS= ... -m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 - - o PentiumPros are known not to require alignment. - - o Super and UltraSparcs: - YAP_EXTRAS= ... -msupersparc - -(b) GCC 2.8.*, EGCS, GCC 2.95.* - - o Check -march=XXX for fun. - - - diff --git a/README.TXT b/README.TXT deleted file mode 100644 index d4de07905..000000000 --- a/README.TXT +++ /dev/null @@ -1,219 +0,0 @@ - - - README for YAP6 - - -This directory contains a release of the YAP 6.3.* Prolog system, -originally developed at the Universidade do Porto by Luis Damas and -Vitor Santos Costa. YAP contains the SWI-Prolog I/O library anad a -number of SWI-Prolog packages, originally developed by Jan Wielemaker -and other. It includes contributions from the Edinburgh Prolog -library, the C-Prolog manual authors, Ricardo Lopes, Ricardo Rocha, -M. Hermenegildo, D. Cabeza, Eric Alphonse, Paulo Moura, Nuno Fonseca, -Jan Wielemaker, Paul Singleton, Fred Dushin, Markus Triska, and many -others. You should read the rest of this file for information on what -YAP is and for instructions on how to build it. - -YAP 6 has been built with several versions on GCC on a variety of -Linux, BDS, and MacOSX configurations. It has been built on Windows7 -using the mingw toolkit and cygwin from Cygnus Solutions. - -The main core of the YAP distribution is distributed under a dual -license: the Perl Artistic license 2 and the FSF's LGPL. The YAP -distribution also contains files distributed under the LGPL -exclusively, and under the GPL. - -The YAP distribution includes several packages ported to YAP. We would -like to take the opportunity to thank the developers of these packages -for their generosity in allowing YAP to distribute these packages. Any -bugs in these packages are probably our fault. - -If you have a question about this software, desire to add code, found -a bug, want to request a feature, or wonder how to get further -assistance, please send e-mail to yap-users@lists.sourceforge.net. To -subscribe to the mailing list or access the list archives, please see -http://lists.sourceforge.net/lists/listinfo/yap-users - -Online documentation is available for YAP at: - - http://www.dcc.fc.up.pt/~vsc/YAP/ - -Recent versions of YAP, including both source and selected binaries, -can be found from this same URL. - -1. What is YAP - -The YAP Prolog System is a high-performance Prolog compiler developed -at LIACC, Universidade do Porto. YAP provides several important -features: - - o speed: YAP is widely considered one of the fastest available Prolog -systems. - - o functionality: it supports stream I/O, sockets, modules, -exceptions, Prolog debugger, C-interface, dynamic code, internal -database, DCGs, saved states, co-routining, arrays. - - o we explicitly allow both commercial and non-commercial use of YAP. - -YAP is based on the David H. D. Warren's WAM (Warren Abstract -Machine), with several optimizations for better performance. YAP -follows the Edinburgh tradition, and was originally designed to be -largely compatible with DEC-10 Prolog, Quintus Prolog, and especially -with C-Prolog. - -YAP implements most of the ISO-Prolog standard. We are striving at -full compatibility, and the manual describes what is still -missing. The manual also includes a (largely incomplete) comparison -with SICStus Prolog. - -2. Obtaining YAP's development sources. - -YAP is now being maintained using the git source management system. A -public repository is available at - -http://sourceforge.net/p/yap/yap-6.3/ci/master/tree/ - -Please use - -git clone git://git.code.sf.net/p/yap/yap-6.3 - -to obtain a copy of the current YAP tree. - -3. How to compile YAP - -First, make sure you have gmp and readline development packages -installed. If you plan to use ProbLog, also check for cudd. - -Now, to compile YAP from the source directory just do: - - (1) ./configure - - (2) check the Makefile for any extensions or changes you want to make. - - (3) make - - (4) If the compilation succeeds, try ./yap - - (5) Happy? "make install" - - (6) "make install_info" will create the info files in the standard - info directory. - - (7) "make html" will create documentation in html format in the - current directory. - -In most systems you will need to be superuser in order to do "make -install" and "make info" on the standard system directories. - -3.1 Where to install YAP - - YAP uses autoconf. Recent versions of YAP try to follow GNU -conventions on where to place software. By default, this location is -/usr/local on Unix, Linux, and OS/X machines. - -You can use the --prefix configure option to set the ROOTDIR macro and -the --exec-prefix option to set the EROOTDIR macro (for -architecture-dependent files). EROOTDIR defaults to ROOTDIR. - - o The main executable is placed at BINDIR, which defaults at -$(EROOTDIR)/bin. - - o SHAREDIR is the directory where the Prolog libraries are stored. -Its default value is $(ROOTDIR)/share. The Prolog libraries are -machine-independent text files that only need to be installed once, -even on systems where multiple copies of YAP of the same version are -installed. (e.g. with different configurations or for different -architectures sharing a file server.) - - o LIBDIR is the directory where binary libraries are stored. It is -set to $(EROOTDIR)/lib by default. YAPLIBDIR is a subdirectory (by -default $(EROOTDIR)/lib/YAP) that contains the Prolog engine and the -binary Prolog libraries. - - o INCLUDEDIR is used if you want to use YAP as a library. - - o INFODIR is where the info help files will be stored. It defaults -to $(SHAREDIR)/info. - -3.2 Which YAP to compile - -Compiling YAP with the standard options give you a plain vanilla -Prolog. You can tune YAP to use extra functionality by using the -following options to configure: - -Compilation options: - - o --enable-tablingt=yes allows tabled evaluation (default option) - - o --enable-depth-limit=yes allows depth limited evaluation, say for -implementing iterative deepening. It is required by the ILP system -Aleph. (default option) - - o --enable-use-malloc=yes makes YAP use the system's C-library - allocation routines for all memory allocation (default). - - o --enable-threads=yes enables POSIX thread support. - - o --enable-pthread-locking=yes always use POSIX p-thread routines for locking. - - o --enable-low-level-tracer=yes allows support for tracing all calls, -retries, and backtracks in the system. This can help in debugging your -application, but results in performance loss. - - o --enable-wam-profile=yes allows profiling of abstract machine -instructions. This is useful when developing YAP, should not be very -useful for normal users. - - o --enable-or-parallelism={env-copy,sba,a-cow} allows or-parallelism -supported by one of these three forms. This is still experimental. - - o --enable-dynamic-loading compile YAP as as a shared library. - - o --enable-cygwin compile YAP as a CYGWIN environment application, and not as stand-alone application. - - o --with-gmp[=GMP_PATH] provide a path for GMP, in case GMP is not - installed in the system. In a Linux machine, make sure you have - installed the gmp-dev package. Binary versions of GMP are available - for WIN32. - - o --enable-condor compile YAP as a static program that can be run by - condor. condor_compile must be in the system path. - -Packages and Interface Libraries - - o --with-cudd[=CUDD_PATH] enables compilation of the CUDD library, - used by packages such as PFL/CLP(BN) and ProbLog. The source of the - CUDD package is availablr from: - - http://vlsi.colorado.edu/~fabio/CUDD - - Fedora Linux and MacPorts have cudd packages. In the case of Fedora, - install cudd-devel. Ask vsc@dcc.fc.up.pt for a WIN32/WIN64 port - - o --with-java[=JAVA_PATH] enables the Java Interface Library JPL. - - o --enable-chr installs the Leuven CHR language implementation - (enabled by default, if package/chr exists) - - o --enable-clpqr installs the Leuven CLPQR port, originally developed - for SWI-Prolog (enabled by default, if Cpackage/clpqe exists) - - o --enable-myddas[=PATH] installs the MYDDAS MYSQL and/or ODBC interface - package (enabled by default, if ODBC and/or MySql - development files can be found). It also enables support for the - SWI-Prolog ODBC package. - - o --with-matlab[=PATH] installs the MATLAB interface (not - default). You need to provide the full path of the MATLAB libraries. - - o --with-mpi[=PATH] installs the MPI interface. This is default, - if the development libraries can be found. - - o --with-gecode[=PATH] installs the GeCode Solver interface. This is default, - if gecode libraries can be found. - - o --with-R[=PATH] installs the Real interface to the R language. - - o --with-python[=PATH] installs a Python interface - diff --git a/README.md b/README.md new file mode 100644 index 000000000..9a5dcee9a --- /dev/null +++ b/README.md @@ -0,0 +1,165 @@ + + +README for YAP6 +==================== + +NOTE: this version of YAP is stil experimental, documentation may be out of date. + +This directory contains a release of the YAP 6.3.* Prolog system, +originally developed at the Universidade do Porto by Luis Damas and +Vitor Santos Costa. YAP contains the SWI-Prolog I/O library anad a +number of SWI-Prolog packages, originally developed by Jan Wielemaker +and other. It includes contributions from the Edinburgh Prolog +library, the C-Prolog manual authors, Ricardo Lopes, Ricardo Rocha, +M. Hermenegildo, D. Cabeza, Eric Alphonse, Paulo Moura, Nuno Fonseca, +Jan Wielemaker, Paul Singleton, Fred Dushin, Markus Triska, Ulrich +Neumerkel, and many others. You should read the rest of this file for +information on what YAP is and for instructions on how to build it. + +YAP 6 has been built with several versions on GCC on a variety of +Linux, BDS, and MacOSX configurations. It has been built on Windows7 +using the mingw toolkit and cygwin from Cygnus Solutions. + +The main core of the YAP distribution is distributed under a dual +license: the Perl Artistic license 2 and the FSF's LGPL. The YAP +distribution also contains files distributed under the LGPL +exclusively, and under the GPL. + +The YAP distribution includes several packages ported to YAP. We would +like to take the opportunity to thank the developers of these packages +for their generosity in allowing YAP to distribute these packages. Any +bugs in these packages are probably our fault. + +If you have a question about this software, desire to add code, found +a bug, want to request a feature, or wonder how to get further +assistance, please send e-mail to yap-users@lists.sourceforge.net. To +subscribe to the mailing list or access the list archives, please see +http://lists.sourceforge.net/lists/listinfo/yap-users + +Online documentation is available for YAP at: + + http://www.dcc.fc.up.pt/~vsc/YAP/ + +Recent versions of YAP, including both source and selected binaries, +can be found from this same URL. + +## What is YAP + +The YAP Prolog System is a high-performance Prolog compiler developed +at LIACC, Universidade do Porto. YAP provides several important +features: + + o speed: YAP is widely considered one of the fastest available Prolog +systems. + + o functionality: it supports stream I/O, sockets, modules, +exceptions, Prolog debugger, C-interface, dynamic code, internal +database, DCGs, saved states, co-routining, arrays. + + o we explicitly allow both commercial and non-commercial use of YAP. + +YAP is based on the David H. D. Warren's WAM (Warren Abstract +Machine), with several optimizations for better performance. YAP +follows the Edinburgh tradition, and was originally designed to be +largely compatible with DEC-10 Prolog, Quintus Prolog, and especially +with C-Prolog. + +YAP implements most of the ISO-Prolog standard. We are striving at +full compatibility. Moreover, we are working on integrating YAP on +multi-programming language environments. + +## Obtaining YAP's development sources. + +YAP is now being maintained using the git source management system. A +public repository is available at + +https://github.com/vscosta/yap-6.3 + +Please use + +git clone git://git.code.sf.net/p/yap/yap-6.3 + +to obtain a copy of the current YAP tree. + +Notice that the current version of YAP does not use submodules + +3. How to compile YAP + +First, make sure you have gmp and readline *development* packages +installed (that is, the headers and libraries). If you are in a WIN32 +environment you will still need GMP. + +Now, to compile YAP from the source directory just do: + + (1) ./configure + + (2) check the Makefile for any extensions or changes you want to make. + + (3) make + + (4) If the compilation succeeds, try ./yap + + (5) Happy? "make install" + + (6) "make install_info" will create the info files in the standard + info directory. + + (7) "make html" will create documentation in html format in the + current directory. + +In most systems you will need to be superuser so that "make +install" can write on the standard system directories. + +# Where to install YAP + + YAP now uses cmake. Still, YAP try to follow GNU conventions on where +to place software. By default, the home location is /usr/local on Unix, +Linux, and OS/X machines. + +You can use the `CMAKE_INSTALL_PREFIX` variable to set the YAP default +home directory. Use the graphical interface to cmake, or from the command line + +~~~~ +cmake -DCMAKE_INSTALL_PREFIX=/home/xpto +~~~~ + + +# Which YAP to compile + +Compiling YAP with the standard options give you a Prolog with +tabling. You can tune YAP to use extra functionality by using the +following options to configure: + +Compilation options: + + * -`DWITH_Threads=ON` enables POSIX thread support. The threads library + mostly follows the SWI design: each thread has its own stack, and + they all share the same data-base. + + * -`DWITH_CALL_TRACER=ON` allows support for tracing all calls, +retries, and backtracks in the system. This can help in debugging a +application, but results in performance loss. It is default in debug mode. + + +# Packages and Interface Libraries + +YAP includes a number of interface libraries. Some, like the Java + interface JPL, have been ported from other Prologs (often from + SWI-Prolog). Others, like the python and swig interface, have been + developed within YAP. + +As an example: + + `-DWITH_CUDD` enables compilation of the CUDD library, used by + packages such as PFL/CLP(BN) and ProbLog. The source of the CUDD + package is available from: + + http://vlsi.colorado.edu/~fabio/CUDD + + Fedora Linux and MacPorts have cudd packages. In the case of Fedora, + install cudd-devel. Ask vsc@dcc.fc.up.pt for a WIN32/WIN64 port + +The cmake graphical interface lists all currently available external packages. + + + diff --git a/Makefile.in b/autoconf/Makefile.in similarity index 100% rename from Makefile.in rename to autoconf/Makefile.in diff --git a/YapTermConfig.h.in b/autoconf/YapTermConfig.h.in similarity index 100% rename from YapTermConfig.h.in rename to autoconf/YapTermConfig.h.in diff --git a/config.guess b/autoconf/config.guess similarity index 100% rename from config.guess rename to autoconf/config.guess diff --git a/config.h.in b/autoconf/config.h.in similarity index 100% rename from config.h.in rename to autoconf/config.h.in diff --git a/config.sub b/autoconf/config.sub similarity index 100% rename from config.sub rename to autoconf/config.sub diff --git a/configure b/autoconf/configure similarity index 100% rename from configure rename to autoconf/configure diff --git a/configure.in b/autoconf/configure.in similarity index 100% rename from configure.in rename to autoconf/configure.in diff --git a/install-sh b/autoconf/install-sh similarity index 100% rename from install-sh rename to autoconf/install-sh