# Adding a python package to an extension/custom Slicer

**URL:** <https://discourse.slicer.org/t/adding-a-python-package-to-an-extension-custom-slicer/4145>\
**Category:** Development\
**Created:** [September 18, 2018, 5:13pm UTC](https://discourse.slicer.org/t/adding-a-python-package-to-an-extension-custom-slicer/4145 "2018-09-18T17:13:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sam\_Horvath](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/sam_horvath/32/3092_2.png) [@Sam\_Horvath](https://discourse.slicer.org/u/Sam_Horvath)\
**Post date:** [September 18, 2018, 5:13pm UTC](https://discourse.slicer.org/t/adding-a-python-package-to-an-extension-custom-slicer/4145/1 "2018-09-18T17:13:58Z")

</div>

I need to add a python package (girder\_client) to a custom Slicer version I am working on. With the current difficulties in using pip in Slicer, I wanted to have it added during the build. Does anyone have an example/tips for doing this?

Thanks

---

<div class="post-metadata">

**Author:** ![jcfr](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jcfr/32/17825_2.png) [@jcfr](https://discourse.slicer.org/u/jcfr)\
**Post date:** [September 18, 2018, 5:33pm UTC](https://discourse.slicer.org/t/adding-a-python-package-to-an-extension-custom-slicer/4145/2 "2018-09-18T17:33:16Z")

</div>

Hi,

Step 1: try to pip install girder client using python 2.7 in slicer in a build tree. I am assuming this will go smoothly.

Step 2: look at [https://github.com/Radiomics/SlicerRadiomics/blob/master/SuperBuild/External\_python-pyradiomics.cmake](https://github.com/Radiomics/SlicerRadiomics/blob/master/SuperBuild/External_python-pyradiomics.cmake) and try to have an extension packing the client along with is dependencies.

Step 3: add that external project to the custom app and update the slicer dependencies like we did for scipy in Slicer Salt.

Hth

Jc
