144554ea0SWill Pazner# LibCEED.jl: Julia Interface for [libCEED](https://github.com/CEED/libCEED) 244554ea0SWill Pazner 3*6f5dc8baSWill PaznerPlease see the [LibCEED.jl 4*6f5dc8baSWill Paznerdocumentation](http://ceed.exascaleproject.org/libCEED-julia-docs/dev/) for 5*6f5dc8baSWill Paznerusage and API documentation. 6*6f5dc8baSWill Pazner 744554ea0SWill Pazner## Installation 844554ea0SWill Pazner 9*6f5dc8baSWill PaznerThe LibCEED.jl package can be installed with Julia's package manager by running 10*6f5dc8baSWill Pazner`] add LibCEED`. This will automatically install a pre-built binary of the 11*6f5dc8baSWill PaznerlibCEED library. If you require features of a specific build of libCEED (e.g. 12*6f5dc8baSWill PaznerCUDA/GPU support, specific compiler flags, etc.) then you should compile your 13*6f5dc8baSWill Paznerown version of the libCEED library, and configure LibCEED.jl to use this binary 14*6f5dc8baSWill Pazneras described in the [Configuring LibCEED.jl](@ref) section. 1544554ea0SWill Pazner 16*6f5dc8baSWill Pazner**Warning:** the pre-built libCEED binaries do not support CUDA backends 17*6f5dc8baSWill Pazner 18*6f5dc8baSWill PaznerThe pre-built binaries automatically installed by LibCEED.jl (through the 19*6f5dc8baSWill Pazner[libCEED_jll](https://juliahub.com/ui/Packages/libCEED_jll/LB2fn) package) are 20*6f5dc8baSWill Paznernot built with CUDA support. If you want to run libCEED on the GPU, you will 21*6f5dc8baSWill Paznerhave to build libCEED from source and configure LibCEED.jl as described in the 22*6f5dc8baSWill Pazner[Configuring LibCEED.jl](@ref) section. 23*6f5dc8baSWill Pazner 24*6f5dc8baSWill Pazner### Configuring LibCEED.jl 25*6f5dc8baSWill Pazner 26*6f5dc8baSWill PaznerBy default, LibCEED.jl will use the pre-built libCEED binaries provided by the 27*6f5dc8baSWill Pazner[libCEED_jll](https://juliahub.com/ui/Packages/libCEED_jll/LB2fn) package. If 28*6f5dc8baSWill Pazneryou wish to use a different libCEED binary (e.g. one built from source), 29*6f5dc8baSWill PaznerLibCEED.jl can be configured using the `JULIA_LIBCEED_LIB` environment variable 30*6f5dc8baSWill Paznerset to the absolute path of the libCEED dynamic library. For the configuration 31*6f5dc8baSWill Paznerto take effect, LibCEED.jl must be **built** with this environment variable, for 32*6f5dc8baSWill Paznerexample: 33*6f5dc8baSWill Pazner 3444554ea0SWill Pazner```julia 3544554ea0SWill Pazner% JULIA_LIBCEED_LIB=/path/to/libceed.so julia 3644554ea0SWill Paznerjulia> # press ] to enter package manager 37*6f5dc8baSWill Pazner(env) pkg> build LibCEED 3844554ea0SWill Pazner``` 3944554ea0SWill Pazneror, equivalently, 4044554ea0SWill Pazner```julia 4144554ea0SWill Paznerjulia> withenv("JULIA_LIBCEED_LIB" => "/path/to/libceed.so") do 42*6f5dc8baSWill Pazner Pkg.build("LibCEED") 4344554ea0SWill Paznerend 4444554ea0SWill Pazner``` 45