Skip to content

Commit

Permalink
Drop Julia 0.6 (#27)
Browse files Browse the repository at this point in the history
  • Loading branch information
bicycle1885 authored Aug 13, 2018
1 parent 0aee068 commit 238f4c2
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 66 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@
deps/deps.jl
deps/src
deps/lib
/Manifest.toml
15 changes: 7 additions & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,19 @@
# Documentation: http://docs.travis-ci.com/user/languages/julia/
# Documentation: https://docs.travis-ci.com/user/languages/julia/
language: julia
os:
- linux
- osx
julia:
- 0.6
- 0.7
- 1.0
- nightly
matrix:
allow_failures:
- julia: nightly
env:
- JULIA_PROJECT="@."
notifications:
email: false
# uncomment the following lines to override the default test script
#script:
# - if [[ -a .git/shallow ]]; then git fetch --unshallow; fi
# - julia -e 'Pkg.clone(pwd()); Pkg.build("CodecZlib"); Pkg.test("CodecZlib"; coverage=true)'
after_success:
# push coverage results to Codecov
- if [ $TRAVIS_JULIA_VERSION != "nightly" ]; then julia -e 'cd(Pkg.dir("CodecZlib")); Pkg.add("Coverage"); using Coverage; Codecov.submit(Codecov.process_folder())'
- julia -e 'using Pkg; Pkg.add("Coverage"); using Coverage; Codecov.submit(Codecov.process_folder())'
- julia -e 'using Pkg; Pkg.add("Documenter"); include(joinpath("docs", "make.jl"))'
5 changes: 2 additions & 3 deletions REQUIRE
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
julia 0.6.0
julia 0.7
BinaryProvider 0.3
Compat 0.62
TranscodingStreams 0.5
TranscodingStreams 0.6
31 changes: 13 additions & 18 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
environment:
matrix:
- JULIA_URL: "https://julialang-s3.julialang.org/bin/winnt/x86/0.6/julia-0.6-latest-win32.exe"
- JULIA_URL: "https://julialang-s3.julialang.org/bin/winnt/x64/0.6/julia-0.6-latest-win64.exe"
- JULIA_URL: "https://julialangnightlies-s3.julialang.org/bin/winnt/x86/julia-latest-win32.exe"
- JULIA_URL: "https://julialangnightlies-s3.julialang.org/bin/winnt/x64/julia-latest-win64.exe"
- julia_version: 0.7
- julia_version: 1.0
- julia_version: latest

platform:
- x86 # 32-bit
- x64 # 64-bit

matrix:
allow_failures:
- JULIA_URL: "https://julialangnightlies-s3.julialang.org/bin/winnt/x86/julia-latest-win32.exe"
- JULIA_URL: "https://julialangnightlies-s3.julialang.org/bin/winnt/x64/julia-latest-win64.exe"
- julia_version: latest

branches:
only:
Expand All @@ -22,19 +24,12 @@ notifications:
on_build_status_changed: false

install:
- ps: "[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.SecurityProtocolType]::Tls12"
# Download most recent Julia Windows binary
- ps: (new-object net.webclient).DownloadFile(
$env:JULIA_URL,
"C:\projects\julia-binary.exe")
# Run installer silently, output to C:\projects\julia
- C:\projects\julia-binary.exe /S /D=C:\projects\julia
- ps: iex ((new-object net.webclient).DownloadString("https://raw.githubusercontent.com/JuliaCI/Appveyor.jl/version-1/bin/install.ps1"))

build_script:
# Need to convert from shallow to complete for Pkg.clone to work
- IF EXIST .git\shallow (git fetch --unshallow)
- C:\projects\julia\bin\julia -e "versioninfo();
Pkg.clone(pwd(), \"CodecZlib\"); Pkg.build(\"CodecZlib\")"
- echo "%JL_BUILD_SCRIPT%"
- C:\julia\bin\julia -e "%JL_BUILD_SCRIPT%"

test_script:
- C:\projects\julia\bin\julia -e "Pkg.test(\"CodecZlib\")"
- echo "%JL_TEST_SCRIPT%"
- C:\julia\bin\julia -e "%JL_TEST_SCRIPT%"
8 changes: 2 additions & 6 deletions deps/build.jl
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using BinaryProvider # requires BinaryProvider 0.3.0 or later
using Compat
using Compat.Libdl

# Parse some basic command-line arguments
const verbose = "--verbose" in ARGS
Expand Down Expand Up @@ -45,22 +43,20 @@ function sourcebuild()
end
cd(joinpath(srcdir, z)) do
run(`./configure --prefix=.`)
make = Compat.Sys.isbsd() ? `gmake` : `make`
make = Sys.isbsd() ? `gmake` : `make`
run(`$make -j$(Sys.CPU_CORES)`)
end
found = false
for f in readdir(joinpath(srcdir, z))
if startswith(f, "libz." * Libdl.dlext)
found = true
Compat.cp(joinpath(srcdir, z, f), joinpath(libdir, f), force=true)
cp(joinpath(srcdir, z, f), joinpath(libdir, f), force=true)
end
end
found || error("zlib was unable to build properly")
libz = joinpath(libdir, "libz." * Libdl.dlext)
open(joinpath(@__DIR__, "deps.jl"), "w") do io
println(io, """
using Compat
using Compat.Libdl
function check_deps()
ptr = Libdl.dlopen_e("$libz")
loaded = ptr != C_NULL
Expand Down
26 changes: 1 addition & 25 deletions src/CodecZlib.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
VERSION < v"0.7.0-beta2.199" && __precompile__()

module CodecZlib

export
Expand Down Expand Up @@ -29,13 +27,7 @@ import TranscodingStreams:
initialize,
finalize,
splitkwargs

using Compat: Cvoid
if VERSION < v"0.7.0-DEV.3382"
using Base.Libdl
else
using Libdl
end
using Libdl

const libzpath = joinpath(dirname(@__FILE__), "..", "deps", "deps.jl")
if !isfile(libzpath)
Expand All @@ -48,20 +40,4 @@ include("libz.jl")
include("compression.jl")
include("decompression.jl")

# Deprecations
# ------------

@deprecate GzipCompression GzipCompressor
@deprecate GzipCompressionStream GzipCompressorStream
@deprecate GzipDecompression GzipDecompressor
@deprecate GzipDecompressionStream GzipDecompressorStream
@deprecate ZlibCompression ZlibCompressor
@deprecate ZlibCompressionStream ZlibCompressorStream
@deprecate ZlibDecompression ZlibDecompressor
@deprecate ZlibDecompressionStream ZlibDecompressorStream
@deprecate DeflateCompression DeflateCompressor
@deprecate DeflateCompressionStream DeflateCompressorStream
@deprecate DeflateDecompression DeflateDecompressor
@deprecate DeflateDecompressionStream DeflateDecompressorStream

end # module
7 changes: 1 addition & 6 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
using CodecZlib
using Compat
if VERSION < v"0.7-"
using Base.Test
else
using Test
end
using Test
import TranscodingStreams:
TranscodingStreams,
TranscodingStream,
Expand Down

0 comments on commit 238f4c2

Please sign in to comment.