Hello Satish,
On 6/16/17 11:36 AM, Satish Sherikar wrote:
Hi,
I want to install ncl. But i have made one change in source code of ncl and that changed source code i want to install with conda.
You would need to re-build the conda package and then install your local version of the package. You’d probably want to start with this conda recipe (assuming you installed “ncl” in the first place from the “conda-forge” channel):
https://github.com/conda-forge/ncl-feedstock
You’d need to modify the recipe to use your locally modified version of NCL, instead of fetching NCL from github. IOW, you’d change this section:
https://github.com/conda-forge/ncl-feedstock/blob/master/recipe/meta.yaml#L7-L10
To be something that looked like this:
https://conda.io/docs/building/meta-yaml.html?highlight=source#source-from-a-local-path
But alternatively you can just compile and install NCL “in the normal way”, just specify your conda environment directory as the installation target. The generic pattern for autoconf-based installations is to do:
./configure --prefix=$CONDA_PREFIX
make && make install
NCL looks like it may require a variation on this, based on its build script:
https://github.com/conda-forge/ncl-feedstock/blob/master/recipe/build.sh
But you could probably just use that build script directly by downloading it into whatever directory contains the “Configure” NCL script and then you would do:
export PREFIX=$CONDA_PREFIX
bash ./build.sh
Of course you’d need to repeat those steps every time you wanted to to install your customized NCL into a new conda environment, and if you expect that to be “semi-regularly” then you are probably better off tweaking the conda-forge feedstock recipe for NCL, building your own local version of the package, and using conda to install that.
If your colleagues need to get it then you could upload it to your own Anaconda Cloud channel:
conda install anaconda-client
anaconda upload /path/to/conda/pkgs/ncl-other-stuff.tar.bz
One important note: you’ll need to manage the version and build numbers yourself so that conda will recognize your version of the conda package as “the latest available version”. I can’t give general advice on how to achieve that, so if it doesn’t appear your package is installing correctly then post back here and we can try to figure out what is going on and how to get things to work the way you need.
Regards,
Ian