Skip to content

Commit

Permalink
remove redundant include joinpath
Browse files Browse the repository at this point in the history
  • Loading branch information
mgkuhn committed Jul 11, 2020
1 parent 9a268ac commit e06a9f5
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/WAV.jl
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,16 @@ using FileIO
using Logging

wavplay(fname) = wavplay(wavread(fname)[1:2]...)
module_dir = dirname(@__FILE__)
@static if Sys.islinux()
@static if Libdl.find_library(["libpulse-simple", "libpulse-simple.so.0"]) != ""
include(joinpath(module_dir, "wavplay-pulse.jl"))
include("wavplay-pulse.jl")
else
wavplay(data, fs) = @warn "libpulse-simple not found, wavplay will not work"
end
elseif Sys.isapple()
@static if Libdl.find_library(["AudioToolbox"],
["/System/Library/Frameworks/AudioToolbox.framework/Versions/A"]) != ""
include(joinpath(module_dir, "wavplay-audioqueue.jl"))
include("wavplay-audioqueue.jl")
else
wavplay(data, fs) = @warn "AudioToolbox.framework not found, wavplay will not work"
end
Expand Down

0 comments on commit e06a9f5

Please sign in to comment.