Skip to content

Commit

Permalink
GSL_jll build 2.6.0+2
Browse files Browse the repository at this point in the history
  • Loading branch information
jlbuild committed Feb 26, 2020
1 parent cb680ca commit d2ed6ee
Show file tree
Hide file tree
Showing 20 changed files with 1,358 additions and 185 deletions.
120 changes: 60 additions & 60 deletions Artifacts.toml
Original file line number Diff line number Diff line change
@@ -1,113 +1,113 @@
[[GSL]]
arch = "armv7l"
git-tree-sha1 = "3152cfb05dc262c142c6b40fe6c6ea303ddc26f5"
libc = "glibc"
arch = "aarch64"
git-tree-sha1 = "88db5d2430f66b051590546c0fc363a9894ff7a2"
libc = "musl"
os = "linux"

[[GSL.download]]
sha256 = "7ff541ba4303c9ad75be81e98b862c60e739d30781dc35502bc9be8a1b9c37b3"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.arm-linux-gnueabihf.tar.gz"
sha256 = "ffa325e6ccbdba722b8877528a90c9e597ead417c44b5fc067c277df7bdd0ee5"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.aarch64-linux-musl.tar.gz"
[[GSL]]
arch = "x86_64"
git-tree-sha1 = "55445e20c1c11e13ed84fa2b4ea01bd83a44f5c5"
libc = "glibc"
os = "linux"
arch = "i686"
git-tree-sha1 = "04559bd3e65c63bc334d4a6c0ed9b6573c4704a0"
os = "windows"

[[GSL.download]]
sha256 = "fb622d543387baf7ba1697bc94a91c52c33601e8d2333e437cf679201d708f63"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.x86_64-linux-gnu.tar.gz"
sha256 = "177da2e8ff0412d1883df47118b32f2d545fc6265027c7bb32528b901f1d4bf9"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.i686-w64-mingw32.tar.gz"
[[GSL]]
arch = "aarch64"
git-tree-sha1 = "83bdc293421a516c63bcc06f5f29a3da91e6392c"
arch = "x86_64"
git-tree-sha1 = "168d36a7558d03ebcf74cb9f2b44b1b208abfd5c"
libc = "musl"
os = "linux"

[[GSL.download]]
sha256 = "3daeac7f648d0b2361c7efe82bed5a65e232fe95ff6e6f7f5d6383d7ffecae6f"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.aarch64-linux-musl.tar.gz"
sha256 = "90853ee3a8a0d5d3fa78c6a3608674cf4fef18af2b309625f5f26109b6a21318"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.x86_64-linux-musl.tar.gz"
[[GSL]]
arch = "powerpc64le"
git-tree-sha1 = "64f44047d62eb3fdc3d049a037c2224b197a7b5c"
arch = "i686"
git-tree-sha1 = "155ff5b3ca275312f3a5f99ab7681de918279583"
libc = "glibc"
os = "linux"

[[GSL.download]]
sha256 = "8a21852fc7318f76eeec17e4a4d75b8a97e629cd19418050a6af0a6e33ff61e8"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.powerpc64le-linux-gnu.tar.gz"
sha256 = "3552f18fbf04be727cec0eeef3ea1c44005de974a3c73b9be25b523b186af1e3"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.i686-linux-gnu.tar.gz"
[[GSL]]
arch = "x86_64"
git-tree-sha1 = "29867afa696e8e6bf1b67e1d7aa011fa7fd8ed89"
os = "macos"
arch = "armv7l"
git-tree-sha1 = "a8acc9af7a876c0ecd093fd068f4be2689f328fc"
libc = "glibc"
os = "linux"

[[GSL.download]]
sha256 = "3019ab03bffdea58af567924bccd11b855510ca2c38050dbd49c5c2fdb5f5a9c"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.x86_64-apple-darwin14.tar.gz"
sha256 = "930d3ba78675137d4505ffac647a0c9504bab25b0fcdfffdaae5025737437cd9"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.armv7l-linux-gnueabihf.tar.gz"
[[GSL]]
arch = "x86_64"
git-tree-sha1 = "8e70a4355b55d3b1bd62dc21e287a9b961177144"
libc = "musl"
arch = "aarch64"
git-tree-sha1 = "3e725ee92c8208d355edb4b13b4a03e1f75e5077"
libc = "glibc"
os = "linux"

[[GSL.download]]
sha256 = "50aee35792a554cf1ebf63c6a02a4483ec694ee289cd4b817c3e21c079753192"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.x86_64-linux-musl.tar.gz"
sha256 = "b1d41224511a3f04e7f0664265e01c44db31facbf3ccf58398385c47673065b1"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.aarch64-linux-gnu.tar.gz"
[[GSL]]
arch = "x86_64"
git-tree-sha1 = "4761f8f4dd6856d22cc8a1aaf85f1902b6b01587"
os = "windows"

[[GSL.download]]
sha256 = "187164dd27ec96d81abc38e366700ca6c6e4fd3df2968dcaefe733a790b87571"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.x86_64-w64-mingw32.tar.gz"
[[GSL]]
arch = "i686"
git-tree-sha1 = "bf23cf8a3204b0a6827f2942207d0d779f0c0eb7"
git-tree-sha1 = "1df9d91478bc51c294bd7c780da90360a23b66e2"
libc = "glibc"
os = "linux"

[[GSL.download]]
sha256 = "da6ef07bd9d04c93686e50b97a2231f70bc4ae7da00f9e0fcdb96cc13621df57"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.i686-linux-gnu.tar.gz"
sha256 = "f97f4a2a771c025066bf4e7d278d51f27c20afc5b275d89527a19937e2e0b28a"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.x86_64-linux-gnu.tar.gz"
[[GSL]]
arch = "aarch64"
git-tree-sha1 = "d822879858aa05f1d1967d8106335b658e26acb5"
arch = "powerpc64le"
git-tree-sha1 = "1caa8db1cc37515bc8b28b0c6a0e7d4be129ac68"
libc = "glibc"
os = "linux"

[[GSL.download]]
sha256 = "93c0e44ea8219e041d0305b77de50e962d172e15016308935eb49e11f7c1154a"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.aarch64-linux-gnu.tar.gz"
sha256 = "78bdf5c6ba578cb4b93f857b032d98679ce04b255f285e391f2c0f63c23751cd"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.powerpc64le-linux-gnu.tar.gz"
[[GSL]]
arch = "i686"
git-tree-sha1 = "8115799bb54682687eb1051f206d608dc6683cb8"
libc = "musl"
os = "linux"
arch = "x86_64"
git-tree-sha1 = "d589c27c39322fe06027038bb6ce5f61cf2a0b1b"
os = "macos"

[[GSL.download]]
sha256 = "d5f76ecb0b3fb0064ffe9a5f1aec77bbeedc00fad9d6dc0323df828b59d64984"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.i686-linux-musl.tar.gz"
sha256 = "f5299f33b516d861b313525778e48cd434db3fd0eb97ffc4a2b780254f13c189"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.x86_64-apple-darwin14.tar.gz"
[[GSL]]
arch = "x86_64"
git-tree-sha1 = "e0187a936ad52b9282b0b24aa4e42795946ef481"
git-tree-sha1 = "127670cf4b82508354a04624e29c5d7f849ffa1a"
os = "freebsd"

[[GSL.download]]
sha256 = "bbf436bf215f0849419d02fa08ad5963e7cb687cd171560e7c7ac238280b1a28"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.x86_64-unknown-freebsd11.1.tar.gz"
sha256 = "08d71bb6a83d54fd00d01fa0e2b61ce4ca33077244f511bb9b140f4a58a3f3db"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.x86_64-unknown-freebsd11.1.tar.gz"
[[GSL]]
arch = "i686"
git-tree-sha1 = "6ea2b138ef2093972aa7648cfc34285b85984989"
os = "windows"
git-tree-sha1 = "bddc6573cca68b7a691314e67dabba73ddbfc225"
libc = "musl"
os = "linux"

[[GSL.download]]
sha256 = "4721221a0cd17845f901b8cfc47c6018d9b8c4d165c519432d0734343b53b50f"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.i686-w64-mingw32.tar.gz"
sha256 = "f94988c7a6837419872cdf40c88155508babc9aa80a7342e2a9ebd2b9531a53a"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.i686-linux-musl.tar.gz"
[[GSL]]
arch = "armv7l"
git-tree-sha1 = "62f163a6e66402fcdd4c9dd9772d93cc44a5d448"
git-tree-sha1 = "8b35de71a6f5508eeeee97ba49e251067042156f"
libc = "musl"
os = "linux"

[[GSL.download]]
sha256 = "d6740e67b0d5804ab3bb94dee1eb1c546b1f5e80516e59f8993265e2ebb456e2"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+1/GSL.v2.6.0.arm-linux-musleabihf.tar.gz"
sha256 = "d6100571f1bcf66c5326dd123a8a62364dfc17f99125971f2a38fd57408f9321"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.armv7l-linux-musleabihf.tar.gz"
[[GSL]]
arch = "x86_64"
git-tree-sha1 = "fe0946bed87be66dd9d4558ccda9b88890665dc6"
os = "windows"

[[GSL.download]]
sha256 = "dc275a8f6e4a8ce5ca865c6ebe6e09b2802d433176bd3baf717cb2976b13ca30"
url = "https://github.com/JuliaBinaryWrappers/GSL_jll.jl/releases/download/GSL-v2.6.0+2/GSL.v2.6.0.x86_64-w64-mingw32.tar.gz"
7 changes: 7 additions & 0 deletions LICENSE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Copyright 2020

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name = "GSL_jll"
uuid = "1b77fbbe-d8ee-58f0-85f9-836ddc23a7a4"
version = "2.6.0+1"
version = "2.6.0+2"

[deps]
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
Libdl = "8f399da3-3557-5675-b5ff-fb832c97cbdb"

[compat]
julia = "1.3"
julia = "1.0"
23 changes: 18 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,22 @@

This is an autogenerated package constructed using [`BinaryBuilder.jl`](https://github.com/JuliaPackaging/BinaryBuilder.jl).

## Usage
## Products

The code bindings within this package are autogenerated from the `Products` defined within the `build_tarballs.jl` file that generated this package. For example purposes, we will assume that the following products were defined:
The code bindings within this package are autogenerated from the following `Products` defined within the `build_tarballs.jl` file that generated this package:

```julia
products = [
LibraryProduct(["libgsl"], :libgsl),
ExecutableProduct(["gsl-histogram"], :gsl_histogram),
ExecutableProduct(["gsl-randist"], :gsl_randist),
LibraryProduct(["libgslcblas"], :libgslcblas)
]
```

## Usage example

For example purposes, we will assume that the following products were defined in the imaginary package `Example_jll`:

```julia
products = [
Expand All @@ -14,18 +27,18 @@ products = [
]
```

With such products defined, this package will contain `data_txt`, `libdataproc` and `mungify_exe` symbols exported. For `FileProduct` variables, the exported value is a string pointing to the location of the file on-disk. For `LibraryProduct` variables, it is a string corresponding to the `SONAME` of the desired library (it will have already been `dlopen()`'ed, so typical `ccall()` usage applies), and for `ExecutableProduct` variables, the exported value is a function that can be called to set appropriate environment variables. Example:
With such products defined, `Example_jll` would contain `data_txt`, `libdataproc` and `mungify_exe` symbols exported. For `FileProduct` variables, the exported value is a string pointing to the location of the file on-disk. For `LibraryProduct` variables, it is a string corresponding to the `SONAME` of the desired library (it will have already been `dlopen()`'ed, so typical `ccall()` usage applies), and for `ExecutableProduct` variables, the exported value is a function that can be called to set appropriate environment variables. Example:

```julia
using GSL_jll
using Example_jll

# For file products, you can access its file location directly:
data_lines = open(data_txt, "r") do io
readlines(io)
end

# For library products, you can use the exported variable name in `ccall()` invocations directly
num_chars = ccall((libdataproc, :count_characters), Cint, (Cstring, Cint), data_lines[1], length(data_lines[1]))
num_chars = ccall((:count_characters, libdataproc), Cint, (Cstring, Cint), data_lines[1], length(data_lines[1]))

# For executable products, you can use the exported variable name as a function that you can call
mungify_exe() do mungify_exe_path
Expand Down
24 changes: 23 additions & 1 deletion src/GSL_jll.jl
Original file line number Diff line number Diff line change
@@ -1,4 +1,23 @@
module GSL_jll

if VERSION < v"1.3.0-rc4"
# We lie a bit in the registry that JLL packages are usable on Julia 1.0-1.2.
# This is to allow packages that might want to support Julia 1.0 to get the
# benefits of a JLL package on 1.3 (requiring them to declare a dependence on
# this JLL package in their Project.toml) but engage in heroic hacks to do
# something other than actually use a JLL package on 1.0-1.2. By allowing
# this package to be installed (but not loaded) on 1.0-1.2, we enable users
# to avoid splitting their package versions into pre-1.3 and post-1.3 branches
# if they are willing to engage in the kinds of hoop-jumping they might need
# to in order to install binaries in a JLL-compatible way on 1.0-1.2. One
# example of this hoop-jumping being to express a dependency on this JLL
# package, then import it wtihin a `VERSION >= v"1.3"` conditional, and use
# the deprecated `build.jl` mechanism to download the binaries through e.g.
# `BinaryProvider.jl`. This should work well for the simplest packages, and
# require greater and greater heroics for more and more complex packages.
error("Unable to import GSL_jll on Julia versions older than 1.3!")
end

using Pkg, Pkg.BinaryPlatforms, Pkg.Artifacts, Libdl
import Base: UUID

Expand All @@ -24,7 +43,10 @@ best_platform = select_platform(Dict(p => triplet(p) for p in platforms))
if best_platform === nothing
@debug("Unable to load GSL; unsupported platform $(triplet(platform_key_abi()))")
else
# Load the appropriate wrapper
# Load the appropriate wrapper. Note that on older Julia versions, we still
# say "arm-linux-gnueabihf" instead of the more correct "armv7l-linux-gnueabihf",
# so we manually correct for that here:
best_platform = replace(best_platform, "arm-" => "armv7l-")
include(joinpath(@__DIR__, "wrappers", "$(best_platform).jl"))
end

Expand Down
89 changes: 88 additions & 1 deletion src/wrappers/aarch64-linux-gnu.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Autogenerated wrapper script for GSL_jll for aarch64-linux-gnu
export libgsl
export libgsl, gsl_histogram, gsl_randist, libgslcblas

## Global variables
PATH = ""
Expand All @@ -20,6 +20,80 @@ libgsl_handle = C_NULL
const libgsl = "libgsl.so.25"


# Relative path to `gsl_histogram`
const gsl_histogram_splitpath = ["bin", "gsl-histogram"]

# This will be filled out by __init__() for all products, as it must be done at runtime
gsl_histogram_path = ""

# gsl_histogram-specific global declaration
function gsl_histogram(f::Function; adjust_PATH::Bool = true, adjust_LIBPATH::Bool = true)
global PATH, LIBPATH
env_mapping = Dict{String,String}()
if adjust_PATH
if !isempty(get(ENV, "PATH", ""))
env_mapping["PATH"] = string(PATH, ':', ENV["PATH"])
else
env_mapping["PATH"] = PATH
end
end
if adjust_LIBPATH
if !isempty(get(ENV, LIBPATH_env, ""))
env_mapping[LIBPATH_env] = string(LIBPATH, ':', ENV[LIBPATH_env])
else
env_mapping[LIBPATH_env] = LIBPATH
end
end
withenv(env_mapping...) do
f(gsl_histogram_path)
end
end


# Relative path to `gsl_randist`
const gsl_randist_splitpath = ["bin", "gsl-randist"]

# This will be filled out by __init__() for all products, as it must be done at runtime
gsl_randist_path = ""

# gsl_randist-specific global declaration
function gsl_randist(f::Function; adjust_PATH::Bool = true, adjust_LIBPATH::Bool = true)
global PATH, LIBPATH
env_mapping = Dict{String,String}()
if adjust_PATH
if !isempty(get(ENV, "PATH", ""))
env_mapping["PATH"] = string(PATH, ':', ENV["PATH"])
else
env_mapping["PATH"] = PATH
end
end
if adjust_LIBPATH
if !isempty(get(ENV, LIBPATH_env, ""))
env_mapping[LIBPATH_env] = string(LIBPATH, ':', ENV[LIBPATH_env])
else
env_mapping[LIBPATH_env] = LIBPATH
end
end
withenv(env_mapping...) do
f(gsl_randist_path)
end
end


# Relative path to `libgslcblas`
const libgslcblas_splitpath = ["lib", "libgslcblas.so"]

# This will be filled out by __init__() for all products, as it must be done at runtime
libgslcblas_path = ""

# libgslcblas-specific global declaration
# This will be filled out by __init__()
libgslcblas_handle = C_NULL

# This must be `const` so that we can use it with `ccall()`
const libgslcblas = "libgslcblas.so.0"


"""
Open all libraries
"""
Expand All @@ -37,6 +111,19 @@ function __init__()
global libgsl_handle = dlopen(libgsl_path)
push!(LIBPATH_list, dirname(libgsl_path))

global gsl_histogram_path = normpath(joinpath(artifact_dir, gsl_histogram_splitpath...))

push!(PATH_list, dirname(gsl_histogram_path))
global gsl_randist_path = normpath(joinpath(artifact_dir, gsl_randist_splitpath...))

push!(PATH_list, dirname(gsl_randist_path))
global libgslcblas_path = normpath(joinpath(artifact_dir, libgslcblas_splitpath...))

# Manually `dlopen()` this right now so that future invocations
# of `ccall` with its `SONAME` will find this path immediately.
global libgslcblas_handle = dlopen(libgslcblas_path)
push!(LIBPATH_list, dirname(libgslcblas_path))

# Filter out duplicate and empty entries in our PATH and LIBPATH entries
filter!(!isempty, unique!(PATH_list))
filter!(!isempty, unique!(LIBPATH_list))
Expand Down
Loading

0 comments on commit d2ed6ee

Please sign in to comment.