Dear ROOT developers,
I have a package which depends solely on ROOT and I would like to ship it with conda.
You can find the package here: https://github.com/javierrico/gLike.
I went through the conda-build
documentation, especially consulting the section on building conda packages from scratch.
The two files needed to build the package are the meta.yaml
package:
name: glike
version: 00.08.00
source:
git_url: https://github.com/javierrico/gLike.git
requirements:
host:
- root
run:
- root
and a build.sh
echo "--> building gLike"
echo "--> check what's in SRC_DIR"
ls $SRC_DIR
export GLIKESYS=$SRC_DIR
export DYLD_LIBRARY_PATH="${GLIKESYS}:${DYLD_LIBRARY_PATH}"
make
(where GLIKESYS
is a local variable needed to make
the code).
The building, performed via
conda build . -c conda-forge
seems to go fine. I get the output messages that the makefile produces while compiling and linking libraries, e.g.
Compiling out/gLikeDict.cc...
g++ -fPIC `root-config --cflags` -c out/gLikeDict.cc -o out/gLikeDict.o
Generated out/gLikeDict.o
Linking shared object lib/libgLike.so...
g++ -fPIC -shared out/Lkl.o out/ParabolaLkl.o out/PoissonLkl.o out/JointLkl.o out/Iact1dUnbinnedLkl.o out/Iact1dBinnedLkl.o out/IactEventListIrf.o out/FermiTables2016Lkl.o out/TemplateLkl.o out/MIACTEventListIRF.o out/GloryDuckTables2019Lkl.o out/gLikeDict.o `root-config --libs` -lMinuit -o lib/libgLike.so
Done!
and additionally the output of conda-build
appears to be the one expected to show up at the end of a successful build - by looking at the documentation
# Automatic uploading is disabled
# If you want to upload package(s) to anaconda.org later, type:
anaconda upload /Users/cosimo/software/miniconda3/conda-bld/osx-64/glike-00.08.00-0.tar.bz2
# To have conda build upload to anaconda.org automatically, use
# $ conda config --set anaconda_upload yes
anaconda_upload is not set. Not uploading wheels: []
####################################################################################
Resource usage summary:
Total time: 0:04:31.5
CPU usage: sys=0:00:00.6, user=0:00:03.5
Maximum memory usage observed: 104.5M
Total disk usage observed (not including envs): 25.8K
####################################################################################
Source and build intermediates have been left in /Users/cosimo/software/miniconda3/conda-bld.
There are currently 2 accumulated.
To remove them, you can run the ```conda build purge``` command
Once the package is built, as a check, it is recommended to try to build it locally. Therefore I try
conda install --use-local glike
but all I get is
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: |
Found conflicts! Looking for incompatible packages.
This can take several minutes. Press CTRL-C to abort.
failed
UnsatisfiableError:
I am stuck: cases outside the python packaging are not well covered by the documentation and the error message I get is not very clear.
Anybody that contributed shipping ROOT with conda could help me?
Thank you,
Cosimo