@@ -13,29 +13,34 @@ if [[ "$(uname)" == "Linux" && -n "$LC_ALL" ]]; then
1313fi
1414
1515
16- echo " Install Miniconda"
17- DEFAULT_CONDA_URL=" https://repo.continuum.io/miniconda/Miniconda3-latest"
18- if [[ " $( uname -m) " == ' aarch64' ]]; then
19- CONDA_URL=" https://github.com/conda-forge/miniforge/releases/download/4.10.1-4/Miniforge3-4.10.1-4-Linux-aarch64.sh"
20- elif [[ " $( uname) " == ' Linux' ]]; then
21- if [[ " $BITS32 " == " yes" ]]; then
22- CONDA_URL=" $DEFAULT_CONDA_URL -Linux-x86.sh"
16+ MINICONDA_DIR=/usr/local/miniconda
17+ if [ -e $MINICONDA_DIR ] && [ " $BITS32 " != yes ]; then
18+ echo " Found Miniconda installation at $MINICONDA_DIR "
19+ else
20+ echo " Install Miniconda"
21+ DEFAULT_CONDA_URL=" https://repo.continuum.io/miniconda/Miniconda3-latest"
22+ if [[ " $( uname -m) " == ' aarch64' ]]; then
23+ CONDA_URL=" https://github.com/conda-forge/miniforge/releases/download/4.10.1-4/Miniforge3-4.10.1-4-Linux-aarch64.sh"
24+ elif [[ " $( uname) " == ' Linux' ]]; then
25+ if [[ " $BITS32 " == " yes" ]]; then
26+ CONDA_URL=" $DEFAULT_CONDA_URL -Linux-x86.sh"
27+ else
28+ CONDA_URL=" $DEFAULT_CONDA_URL -Linux-x86_64.sh"
29+ fi
30+ elif [[ " $( uname) " == ' Darwin' ]]; then
31+ CONDA_URL=" $DEFAULT_CONDA_URL -MacOSX-x86_64.sh"
2332 else
24- CONDA_URL=" $DEFAULT_CONDA_URL -Linux-x86_64.sh"
33+ echo " OS $( uname) not supported"
34+ exit 1
2535 fi
26- elif [[ " $( uname) " == ' Darwin' ]]; then
27- CONDA_URL=" $DEFAULT_CONDA_URL -MacOSX-x86_64.sh"
28- else
29- echo " OS $( uname) not supported"
30- exit 1
31- fi
32- echo " Downloading $CONDA_URL "
33- wget -q $CONDA_URL -O miniconda.sh
34- chmod +x miniconda.sh
36+ echo " Downloading $CONDA_URL "
37+ wget -q $CONDA_URL -O miniconda.sh
38+ chmod +x miniconda.sh
3539
36- MINICONDA_DIR=" $HOME /miniconda3"
37- rm -rf $MINICONDA_DIR
38- ./miniconda.sh -b -p $MINICONDA_DIR
40+ MINICONDA_DIR=" $HOME /miniconda3"
41+ rm -rf $MINICONDA_DIR
42+ ./miniconda.sh -b -p $MINICONDA_DIR
43+ fi
3944export PATH=$MINICONDA_DIR /bin:$PATH
4045
4146echo
4651echo " update conda"
4752conda config --set ssl_verify false
4853conda config --set quiet true --set always_yes true --set changeps1 false
49- conda install pip conda # create conda to create a historical artifact for pip & setuptools
50- conda update -n base conda
51- conda install -y -c conda-forge mamba
54+ # TODO: GH#44980 https://github.com/pypa/setuptools/issues/2941
55+ conda install -y -c conda-forge -n base ' mamba>=0.21.2' pip
5256
5357echo " conda info -a"
5458conda info -a
5559
56- echo " source deactivate"
57- source deactivate
58-
5960echo " conda list (root environment)"
6061conda list
6162
63+ echo
6264# Clean up any left-over from a previous build
63- conda remove --all -q -y -n pandas-dev
65+ mamba env remove -n pandas-dev
66+ echo " mamba env update --file=${ENV_FILE} "
67+ # See https://github.com/mamba-org/mamba/issues/633
68+ mamba create -q -n pandas-dev
69+ time mamba env update -n pandas-dev --file=" ${ENV_FILE} "
70+ # TODO: GH#44980 https://github.com/pypa/setuptools/issues/2941
71+ mamba install -n pandas-dev ' setuptools<60'
6472
65- echo
66- echo " mamba env create -q --file=${ENV_FILE} "
67- time mamba env create -q --file=" ${ENV_FILE} "
73+ echo " conda list -n pandas-dev"
74+ conda list -n pandas-dev
6875
6976
7077if [[ " $BITS32 " == " yes" ]]; then
@@ -81,35 +88,23 @@ source activate pandas-dev
8188# downstream CI jobs that may also build pandas from source.
8289export PANDAS_CI=1
8390
84- echo
85- echo " remove any installed pandas package"
86- echo " w/o removing anything else"
87- conda remove pandas -y --force || true
88- pip uninstall -y pandas || true
89-
90- echo
91- echo " remove qt"
92- echo " causes problems with the clipboard, we use xsel for that"
93- conda remove qt -y --force || true
94-
95- echo
96- echo " conda list pandas"
97- conda list pandas
98-
99- # Make sure any error below is reported as such
91+ if pip list | grep -q ^pandas; then
92+ echo
93+ echo " remove any installed pandas package w/o removing anything else"
94+ pip uninstall -y pandas || true
95+ fi
10096
101- echo " [Build extensions]"
102- python setup.py build_ext -q -j2
97+ if [ " $( conda list -f qt --json) " != [] ]; then
98+ echo
99+ echo " remove qt"
100+ echo " causes problems with the clipboard, we use xsel for that"
101+ conda remove qt -y --force || true
102+ fi
103103
104- echo " [Updating pip]"
105- # TODO: GH#44980 https://github.com/pypa/setuptools/issues/2941
106- python -m pip install --no-deps -U pip wheel " setuptools<60.0.0"
104+ echo " Build extensions"
105+ python setup.py build_ext -q -j3
107106
108- echo " [ Install pandas] "
107+ echo " Install pandas"
109108python -m pip install --no-build-isolation -e .
110109
111- echo
112- echo " conda list"
113- conda list
114-
115110echo " done"
0 commit comments