Skip to content

Commit

Permalink
rebase on top of latest master
Browse files Browse the repository at this point in the history
  • Loading branch information
jakebolewski committed Oct 6, 2014
2 parents a8fec91 + b5a0f5f commit c562ef9
Show file tree
Hide file tree
Showing 341 changed files with 25,042 additions and 6,463 deletions.
18 changes: 10 additions & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ notifications:
email: false
irc:
channels:
- "chat.freenode.net#julia"
- "chat.freenode.net#julia-notifications"
on_success: change
on_failure: always
webhooks:
Expand All @@ -17,24 +17,26 @@ notifications:
before_install:
- if [ `uname` = "Linux" ]; then
BUILDOPTS="USEGCC=1 LLVM_CONFIG=llvm-config-3.3 LLVM_LLC=llc-3.3 VERBOSE=1 USE_BLAS64=0";
for lib in LLVM ZLIB SUITESPARSE ARPACK BLAS FFTW LAPACK GMP MPFR PCRE LIBUNWIND GRISU OPENLIBM RMATH; do
for lib in LLVM ZLIB SUITESPARSE ARPACK BLAS FFTW LAPACK GMP MPFR PCRE LIBUNWIND OPENLIBM RMATH; do
export BUILDOPTS="$BUILDOPTS USE_SYSTEM_$lib=1";
done;
sudo apt-get update -qq -y;
sudo apt-get install zlib1g-dev;
sudo add-apt-repository ppa:staticfloat/julia-deps -y;
sudo apt-get update -qq -y;
sudo apt-get install patchelf gfortran llvm-3.3-dev libsuitesparse-dev libopenblas-dev liblapack-dev libarpack2-dev libfftw3-dev libgmp-dev libpcre3-dev libunwind7-dev libdouble-conversion-dev libopenlibm-dev librmath-dev libmpfr-dev -y;
sudo apt-get install patchelf gfortran llvm-3.3-dev libsuitesparse-dev libopenblas-dev liblapack-dev libarpack2-dev libfftw3-dev libgmp-dev libpcre3-dev libunwind7-dev libopenlibm-dev librmath-dev libmpfr-dev -y;
elif [ `uname` = "Darwin" ]; then
BUILDOPTS="USECLANG=1 LLVM_CONFIG=llvm-config-3.3 LLVM_LLC=llc-3.3 VERBOSE=1 USE_BLAS64=0 SUITESPARSE_INC='-I/usr/local/include'";
BUILDOPTS="$BUILDOPTS LIBBLAS=-lopenblas LIBBLASNAME=libopenblas LIBLAPACK=-lopenblas LIBLAPACKNAME=libopenblas";
for lib in LLVM ZLIB SUITESPARSE ARPACK BLAS FFTW LAPACK GMP MPFR PCRE LIBUNWIND; do
export BUILDOPTS="$BUILDOPTS USE_SYSTEM_$lib=1";
done;
brew tap staticfloat/julia;
brew install -v --only-dependencies --HEAD julia;
brew update;
brew upgrade gcc;
BUILDOPTS="USECLANG=1 LLVM_CONFIG=$(brew --prefix llvm33-julia)/bin/llvm-config-3.3 VERBOSE=1 USE_BLAS64=0 SUITESPARSE_INC=-I$(brew --prefix suite-sparse-julia)/include";
BUILDOPTS="$BUILDOPTS LIBBLAS=-lopenblas LIBBLASNAME=libopenblas LIBLAPACK=-lopenblas LIBLAPACKNAME=libopenblas";
for lib in LLVM ZLIB SUITESPARSE ARPACK BLAS FFTW LAPACK GMP MPFR PCRE LIBUNWIND; do
export BUILDOPTS="$BUILDOPTS USE_SYSTEM_$lib=1";
done;
export LDFLAGS="-L$(brew --prefix openblas-julia)/lib -L$(brew --prefix suite-sparse-julia)/lib";
export DYLD_FALLBACK_LIBRARY_PATH="/usr/local/lib:/lib:/usr/lib:$(brew --prefix openblas-julia)/lib:$(brew --prefix suite-sparse-julia)/lib:$(brew --prefix arpack-julia)/lib";
make $BUILDOPTS -C contrib -f repackage_system_suitesparse4.make;
fi
script:
Expand Down
14 changes: 14 additions & 0 deletions ARM.inc
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
FORCE_ARMV7=1
LLVM_ASSERTIONS=1

override OPENBLAS_DYNAMIC_ARCH=0
override OPENBLAS_TARGET_ARCH=ARMV7

override LLVM_VER=3.5.0

override USE_SYSTEM_BLAS=1
override USE_SYSTEM_LAPACK=1
override USE_SYSTEM_LIBM=1
override USE_SYSTEM_FFTW=1
override USE_SYSTEM_GMP=1
override USE_SYSTEM_MPFR=1
55 changes: 49 additions & 6 deletions DISTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ order to create a portable, working Julia distribution, we have
separated most of the notes by OS.

Note that while the code for Julia is
[MIT-licensed](https://github.com/JuliaLang/julia/blob/master/LICENSE.md),
[MIT-licensed, with a few exceptions](https://github.com/JuliaLang/julia/blob/master/LICENSE.md),
the distribution created by the techniques described herein will be
GPL licensed, as various dependent libraries such as `FFTW`, `Rmath`,
`SuiteSparse`, and `git` are GPL licensed. We do hope to have a
Expand All @@ -26,7 +26,7 @@ pregenerate the `base/version_git.jl` file with:

make -C base version_git.jl.phony

Juila has lots of build dependencies where we use patched versions that has not
Julia has lots of build dependencies where we use patched versions that has not
yet been included by the popular package managers. These dependencies will usually
be automatically downloaded when you build, but if you want to be able to build
Julia on a computer without internet access you should create a source-dist archive
Expand All @@ -43,6 +43,25 @@ to create a Make.user file containing:

override TAGGED_RELEASE_BANNER = "my-package-repository build"

Target Architectures
--------------------

By default, Julia optimizes its system image to the native architecture of
the build machine. This is usually not what you want when building packages,
as it will make Julia fail at startup on any machine with incompatible CPUs
(in particular older ones with more restricted instruction sets).

We therefore recommend that you pass the `MARCH` variable when calling `make`,
setting it to the baseline target you intend to support. This will determine
the target CPU for both the Julia executable and libraries, and the system
image (the latter can also be set using `JULIA_CPU_TARGET`). Typically useful
values for x86 CPUs are `x86-64` and `core2` (for 64-bit builds) and
`pentium4` (for 32-bit builds). Unfortunately, CPUs older than Pentium 4
are currently not supported (see
[this issue](https://github.com/JuliaLang/julia/issues/7185)).

The full list of CPU targets supported by LLVM can be obtained by running
`llc -mattr=help`.

Linux
-----
Expand All @@ -52,10 +71,17 @@ installation. If you wish to create a distribution package such as a
`.deb`, or `.rpm`, some extra effort is needed. See the
[julia-debian](http:https://github.com/staticfloat/julia-debian) repository
for an example of what metadata is needed for creating `.deb` packages
for Debian and Ubuntu-based systems. Although we have not yet experimented
for Debian and Ubuntu-based systems. See the
[Fedora package](https://admin.fedoraproject.org/pkgdb/package/julia/)
for RPM-based distributions. Although we have not yet experimented
with it, [Alien](https://wiki.debian.org/Alien) could be used to
generate Julia packages for various Linux distributions.

Julia supports overriding standard installation directories via `prefix`
and other environment variables you can pass when calling `make` and
`make install`. See Make.inc for their list. `DESTDIR` can also be used
to force the installation into a temporary directory.

By default, Julia loads `$prefix/etc/julia/juliarc.jl` as an
installation-wide initialization file. This file can be used by
distribution managers to provide paths to various binaries such as a
Expand Down Expand Up @@ -102,8 +128,8 @@ Notes on BLAS and LAPACK
Julia builds OpenBLAS by default, which includes the BLAS and LAPACK
libraries. On 32-bit architectures, Julia builds OpenBLAS to use
32-bit integers, while on 64-bit architectuers, Julia builds OpenBLAS
to use 64-bit integers. It is essential that all Julia functions that
call BLAS and LAPACK API routines use integers of the correct width.
to use 64-bit integers (ILP64). It is essential that all Julia functions
that call BLAS and LAPACK API routines use integers of the correct width.

Most BLAS and LAPACK distributions provided on linux distributions,
and even commercial implementations ship libraries that use 32-bit
Expand All @@ -120,6 +146,22 @@ all libraries that depend on BLAS and LAPACK. The Julia build process
will build all these libraries correctly, but when overriding defaults
and using system provided libraries, this consistency must be ensured.

Also note that Linux distributions sometimes ship several versions of
OpenBLAS, some of which enable multithreading, and others only working
in a serial fashion. For example, in Fedora, `libopenblasp.so` is threaded,
but `libopenblas.so` is not. We recommend using the former for optimal
performance. To choose an OpenBLAS library whose name is different from
the default `libopenblas.so`, pass `LIBBLAS=-l$(YOURBLAS)` and
`LIBBLASNAME=lib$(YOURBLAS)` to `make`, replacing `$(YOURBLAS)` with the
name of your library. You can also add `.so.0` to the name of the library
if you want your package to work without requiring the unversioned `.so`
symlink.

Finally, OpenBLAS includes its own optimized version of LAPACK. If you
set `USE_SYSTEM_BLAS=1` and `USE_SYSTEM_LAPACK=1`, you should also set
`LIBLAPACK=-l$(YOURBLAS)` and `LIBLAPACKNAME=lib$(YOURBLAS)`. Else, the
reference LAPACK will be used and performance will typically be much lower.

Notes on Rmath
==============

Expand All @@ -136,7 +178,8 @@ used.
Compilation scripts
===================

The [julia-nightly-packaging](https://github.com/staticfloat/julia-nightly-packaging) repository contains multiple example scripts to ease the creation of
The [julia-nightly-packaging](https://github.com/staticfloat/julia-nightly-packaging)
repository contains multiple example scripts to ease the creation of
binary packages. It also includes miscellaneous tools to do things such as
fetching the last good commit that passed the
[Travis](https://travis-ci.org/JuliaLang/julia/builds) tests.
Expand Down
55 changes: 42 additions & 13 deletions LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
Julia is licensed under the MIT License:
The Julia language is licensed under the MIT License. The "language" consists
of the compiler (the contents of src/), most of the standard library (base/),
and some utilities (most of the rest of the files in this repository). See below
for exceptions.

> Copyright (c) 2009-2014: Jeff Bezanson, Stefan Karpinski, Viral B. Shah,
> and other contributors:
Expand All @@ -24,33 +27,59 @@ Julia is licensed under the MIT License:
> OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
> WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
External libraries, if used, include their own licenses:

The Julia language links to the following external libraries, which have their
own licenses:

- [FEMTOLISP](https://github.com/JeffBezanson/femtolisp)
- [LIBUNWIND](http:https://git.savannah.gnu.org/gitweb/?p=libunwind.git;a=blob_plain;f=LICENSE;hb=master)
- [LIBUV](https://github.com/joyent/libuv/blob/master/LICENSE)
- [LLVM](http:https://llvm.org/releases/3.3/LICENSE.TXT)
- [LIBMOJIBAKE](https://github.com/JuliaLang/libmojibake)


Julia's standard library uses the following external libraries, which have
their own licenses:

- [AMOS](http:https://www.netlib.org/slatec/guide)
- [ARPACK](http:https://www.caam.rice.edu/software/ARPACK/RiceBSD.txt#LICENSE)
- [ATLAS](http:https://math-atlas.sourceforge.net/faq.html#license)
- [DOUBLE-CONVERSION](https://code.google.com/p/double-conversion/)
- [DSFMT](http:https://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/SFMT/LICENSE.txt)
- [OPENLIBM](https://github.com/JuliaLang/openlibm/blob/master/LICENSE.md)
- [OPENSPECFUN](https://github.com/JuliaLang/openspecfun)
- [FADDEEVA](http:https://ab-initio.mit.edu/Faddeeva)
- [FEMTOLISP](https://github.com/JeffBezanson/femtolisp)
- [FFTW](http:https://fftw.org/doc/License-and-Copyright.html)
- [GMP](http:https://gmplib.org/manual/Copying.html#Copying)
- [LAPACK](http:https://netlib.org/lapack/LICENSE.txt)
- [LIBEXPAT](http:https://expat.cvs.sourceforge.net/viewvc/expat/expat/README)
- [LIBUNWIND](http:https://git.savannah.gnu.org/gitweb/?p=libunwind.git;a=blob_plain;f=LICENSE;hb=master)
- [LIBUV](https://github.com/joyent/libuv/blob/master/LICENSE)
- [LLVM](http:https://llvm.org/releases/3.0/LICENSE.TXT)
- [MPFR](http:https://www.mpfr.org/mpfr-current/mpfr.html#Copying)
- [MUSL](http:https://git.musl-libc.org/cgit/musl/tree/COPYRIGHT)
- [OPENBLAS](https://raw.github.com/xianyi/OpenBLAS/master/LICENSE)
- [PATCHELF](http:https://hydra.nixos.org/build/1524660/download/1/README)
- [LAPACK](http:https://netlib.org/lapack/LICENSE.txt)
- [PCRE](http:https://www.pcre.org/licence.txt)
- [SUITESPARSE](http:https://faculty.cse.tamu.edu/davis/suitesparse.html)


The following components of Julia's standard library have separate licenses:

- base/fftw.jl (see [FFTW](http:https://fftw.org/doc/License-and-Copyright.html))
- base/sparse/csparse.jl (LGPL-2.1+)
- base/linalg/umfpack.jl (see [SUITESPARSE](http:https://faculty.cse.tamu.edu/davis/suitesparse.html))
- base/linalg/cholmod.jl (see [SUITESPARSE](http:https://faculty.cse.tamu.edu/davis/suitesparse.html))


Julia builds the following libraries by default, but does not use them itself:

- [RMATH](http:https://www.r-project.org/Licenses/)
- [SUITESPARSE](http:https://www.cise.ufl.edu/research/sparse/SuiteSparse/current/SuiteSparse/)
- [ZLIB](http:https://zlib.net/zlib_license.html)

Julia bundles the following as external executables on some platforms:

Julia's build process uses the following external tools:

- [PATCHELF](http:https://hydra.nixos.org/build/1524660/download/1/README)


Julia bundles the following external programs and libraries on some platforms:

- [7-Zip](http:https://www.7-zip.org/license.txt)
- [BUSYBOX](https://github.com/rmyorston/busybox-w32/blob/master/LICENSE)
- [GIT](http:https://git-scm.com/about/free-and-open-source)
- [ZLIB](http:https://zlib.net/zlib_license.html)
- [LIBEXPAT](http:https://expat.cvs.sourceforge.net/viewvc/expat/expat/README)
Loading

0 comments on commit c562ef9

Please sign in to comment.