BinDeps.jl icon indicating copy to clipboard operation
BinDeps.jl copied to clipboard

Prefer Autotools overs other providers?

Open habemus-papadum opened this issue 9 years ago • 7 comments

Hi -- is it possible to force BinDeps to always prefer Autotools over other providers (in my particular case yum)?

At a higher level, I want to be able to test new Pkgs without impacting the system state (the way Homebrew.jl isolates itself from the user's homebrew is quite nice -- I don't thing the Yum and Apt providers can do this -- please correct me if I am wrong). My typical flow is to launch julia with the JULIA_PKGDIR set to a temp directory, play around with new packages, and then just revert to my old state if things don't work out by nuking the temp dir -- but this doesn't quite work if BinDeps needs to pull in new packages via yum.

thanks!

habemus-papadum avatar Sep 05 '15 19:09 habemus-papadum

+1 It would be useful to be able to prevent BinDeps from using yum. I currently have to do chmod 000 /usr/bin/yum before running mu Julia build script when building on EC2 for deployment on AWS Lambda.

samoconnor avatar Apr 26 '16 02:04 samoconnor

See related: https://github.com/JuliaLang/Cairo.jl/issues/133

samoconnor avatar Apr 26 '16 07:04 samoconnor

I guess we could check for an environment variable, e.g. JULIA_BINDEPS_SYSTEM_INSTALL=0. Shouldn't be too hard to do. Would you give it a try?

nalimilan avatar Apr 26 '16 09:04 nalimilan

See alternative suggestions in https://github.com/JuliaLang/Cairo.jl/issues/133#issuecomment-214913819 :

ENV["JULIA_BINDEPS_DISABLE"] = "apt yum" ENV["JULIA_BINDEPS_IGNORE"] = "freetype fontconfig"

samoconnor avatar Apr 26 '16 23:04 samoconnor

The point of JULIA_BINDEPS_SYSTEM_INSTALL=0 is that it would disable all distro packager tools. A system generally only supports one packager, so it's not terribly useful to be able to pass several of them. OTOH, some packaging tools like Homebrew can be used either system-wide or for the current user.

nalimilan avatar Apr 27 '16 10:04 nalimilan

You can mutate and rearrange the BinDeps.defaults array in your deps/build.jl script, but make sure to put it back the way it started when you're done so it doesn't change behavior of any later libraries that build in the same process.

tkelman avatar Apr 27 '16 10:04 tkelman

Related: https://github.com/JuliaLang/BinDeps.jl/issues/69#issuecomment-29644044 says...

+1 for having exposing a way to test different providers without having to comment out providers that have higher priority. For example, OS X users should be able to compile from source without needing to comment out the provider lines for Homebrew.

samoconnor avatar Apr 27 '16 23:04 samoconnor