title: Uinstalling matplotlib after installing with setup.py
body: <p>I installed matplotlib from source, running <code>python3 setup.py install</code> after getting it from here: <a href="https://github.com/matplotlib/matplotlib" rel="nofollow noreferrer">https://github.com/matplotlib/matplotlib</a></p>
  
  <p>How do I uninstall this? (I forgot to do it in a container)</p>
  
  <p>This answer <a href="https://stackoverflow.com/questions/1231688/how-do-i-remove-packages-installed-with-pythons-easy-install">How do I remove packages installed with Python&#39;s easy_install?</a> shows how to do it using pip but I did not use pip to install it, and I'm not sure what the package is called.</p>
  
  <p>matplotlib didn't sucessfully install, but it copied a lot of files into build folder and think ran build.</p>
  
  <p>Here is part of what was being printed when it was being installed:</p>
  
  <pre><code>python3 setup.py install
  IMPORTANT WARNING:
      pkg-config is not installed.
      matplotlib may not be able to find some of its dependencies
  ================================================================================
  Edit setup.cfg to change the build options
  
  BUILDING MATPLOTLIB
    matplotlib: yes [0+untagged.1.g692ab97]
        python: yes [3.7.2 (default, Jan 13 2019, 12:50:15)  [Clang 10.0.0
                    (clang-1000.11.45.5)]]
      platform: yes [darwin]
  
  OPTIONAL SUBPACKAGES
   sample_data: yes [installing]
         tests: yes [installing]
  
  OPTIONAL BACKEND EXTENSIONS
           agg: yes [installing]
         tkagg: yes [installing; run-time loading from Python Tcl/Tk]
        macosx: yes [installing, darwin]
  
  OPTIONAL PACKAGE DATA
          dlls: no  [skipping due to configuration]
  
  running install
  running bdist_egg
  running egg_info
  creating lib/matplotlib.egg-info
  writing lib/matplotlib.egg-info/PKG-INFO
  writing dependency_links to lib/matplotlib.egg-info/dependency_links.txt
  writing namespace_packages to lib/matplotlib.egg-info/namespace_packages.txt
  writing requirements to lib/matplotlib.egg-info/requires.txt
  writing top-level names to lib/matplotlib.egg-info/top_level.txt
  writing manifest file 'lib/matplotlib.egg-info/SOURCES.txt'
  reading manifest file 'lib/matplotlib.egg-info/SOURCES.txt'
  reading manifest template 'MANIFEST.in'
  writing manifest file 'lib/matplotlib.egg-info/SOURCES.txt'
  installing library code to build/bdist.macosx-10.13-x86_64/egg
  running install_lib
  running build_py
  creating build
  creating build/lib.macosx-10.13-x86_64-3.7
  copying lib/pylab.py -&gt; build/lib.macosx-10.13-x86_64-3.7
  creating build/lib.macosx-10.13-x86_64-3.7/mpl_toolkits
  copying lib/mpl_toolkits/__init__.py -&gt; build/lib.macosx-10.13-x86_64-3.7/mpl_toolkits
  creating build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/hatch.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/transforms.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/legend_handler.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/axis.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/textpath.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/quiver.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/backend_bases.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/units.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/pylab.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/colorbar.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/_version.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/_cm.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/backend_managers.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/mathtext.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/font_manager.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib
  copying lib/matplotlib/bezier.py -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/mpl-data/fonts/afm/pcrbo8a.afm -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/mpl-data/fonts/afm
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_dejavuserif_82.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_text/multiline2.pdf -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_text
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_stix_79.pdf -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_cm_66.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_stix_81.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_dejavuserif_57.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_patches/multi_color_hatch.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_patches
  copying lib/matplotlib/tests/baseline_images/test_text/text_alignment.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_text
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_stix_51.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathfont_cm_13.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/backends/web_backend/jquery/css/themes/base/images/ui-icons_ef8c08_256x240.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/backends/web_backend/jquery/css/themes/base/images
  copying lib/matplotlib/tests/baseline_images/test_axes/axvspan_epoch.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_axes
  copying lib/matplotlib/tests/baseline_images/test_axes/polar_wrap_180.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_axes
  copying lib/matplotlib/tests/baseline_images/test_tightlayout/tight_layout1.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_tightlayout
  copying lib/matplotlib/tests/baseline_images/test_quiver/quiver_with_key_test_image.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_quiver
  copying lib/matplotlib/tests/baseline_images/test_scale/logscale_nonpos_values.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_scale
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_dejavusans_47.pdf -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_axes/hist_step_bottom.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_axes
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_stixsans_01.pdf -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_simplification/fft_peaks.pdf -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_simplification
  copying lib/matplotlib/tests/baseline_images/test_legend/framealpha.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_legend
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_dejavuserif_37.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/mpl-data/images/subplots_large.gif -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/mpl-data/images
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_dejavusans_80.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_stix_28.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_dejavuserif_48.pdf -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathfont_stixsans_02.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/mpl-data/images/hand.pdf -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/mpl-data/images
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_cm_70.pdf -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_axes/bxp_baseline.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_axes
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_stixsans_53.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  copying lib/matplotlib/tests/baseline_images/test_legend/scatter_rc1.pdf -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_legend
  copying lib/matplotlib/tests/baseline_images/test_axes/axhspan_epoch.svg -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_axes
  copying lib/matplotlib/tests/baseline_images/test_mathtext/mathtext_cm_01.png -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/tests/baseline_images/test_mathtext
  UPDATING build/lib.macosx-10.13-x86_64-3.7/matplotlib/_version.py
  set build/lib.macosx-10.13-x86_64-3.7/matplotlib/_version.py to '0+untagged.1.g692ab97'
  running build_ext
  building 'matplotlib.ft2font' extension
  creating build/temp.macosx-10.13-x86_64-3.7
  creating build/temp.macosx-10.13-x86_64-3.7/src
  clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers -DFREETYPE_BUILD_TYPE=system -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib_ft2font_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -I/Users/ahmedayman/Documents/CSCD01/matplotlib/.eggs/numpy-1.16.1-py3.7-macosx-10.13-x86_64.egg/numpy/core/include -Iextern/agg24-svn/include -I/usr/local/include -I/usr/include -I. -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.7.2_1/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c src/checkdep_freetype2.c -o build/temp.macosx-10.13-x86_64-3.7/src/checkdep_freetype2.o
  src/checkdep_freetype2.c:1:10: fatal error: 'ft2build.h' file not found
  #include &lt;ft2build.h&gt;
           ^~~~~~~~~~~~
  1 error generated.
  error: command 'clang' failed with exit status 1
  Ahmeds-MacBook-Air:matplotlib ahmedayman$ ls
  INSTALL.rst     doc         setupext.py
  LICENSE         examples        src
  MANIFEST.in     extern          tests.py
  README.rst      lib         tools
  __pycache__     matplotlibrc.template   tox.ini
  azure-pipelines.yml pytest.ini      tutorials
  build           requirements        versioneer.py
  build_alllocal.cmd  setup.cfg.template
  ci          setup.py
  Ahmeds-MacBook-Air:matplotlib ahmedayman$ python setup.py install --record files.txt
  
  Beginning with Matplotlib 3.1, Python 3.6 or above is required.
  
  This may be due to an out of date pip.
  
  Make sure you have pip &gt;= 9.0.1.
  
  Ahmeds-MacBook-Air:matplotlib ahmedayman$ python3 setup.py install --record files.txt
  IMPORTANT WARNING:
      pkg-config is not installed.
      matplotlib may not be able to find some of its dependencies
  ================================================================================
  Edit setup.cfg to change the build options
  
  BUILDING MATPLOTLIB
    matplotlib: yes [0+untagged.1.g692ab97]
        python: yes [3.7.2 (default, Jan 13 2019, 12:50:15)  [Clang 10.0.0
                    (clang-1000.11.45.5)]]
      platform: yes [darwin]
  
  OPTIONAL SUBPACKAGES
   sample_data: yes [installing]
         tests: yes [installing]
  
  OPTIONAL BACKEND EXTENSIONS
           agg: yes [installing]
         tkagg: yes [installing; run-time loading from Python Tcl/Tk]
        macosx: yes [installing, darwin]
  
  OPTIONAL PACKAGE DATA
          dlls: no  [skipping due to configuration]
  
  running install
  running bdist_egg
  running egg_info
  writing lib/matplotlib.egg-info/PKG-INFO
  writing dependency_links to lib/matplotlib.egg-info/dependency_links.txt
  writing namespace_packages to lib/matplotlib.egg-info/namespace_packages.txt
  writing requirements to lib/matplotlib.egg-info/requires.txt
  writing top-level names to lib/matplotlib.egg-info/top_level.txt
  reading manifest file 'lib/matplotlib.egg-info/SOURCES.txt'
  reading manifest template 'MANIFEST.in'
  writing manifest file 'lib/matplotlib.egg-info/SOURCES.txt'
  installing library code to build/bdist.macosx-10.13-x86_64/egg
  running install_lib
  running build_py
  copying lib/matplotlib/mpl-data/matplotlibrc -&gt; build/lib.macosx-10.13-x86_64-3.7/matplotlib/mpl-data
  UPDATING build/lib.macosx-10.13-x86_64-3.7/matplotlib/_version.py
  set build/lib.macosx-10.13-x86_64-3.7/matplotlib/_version.py to '0+untagged.1.g692ab97'
  running build_ext
  building 'matplotlib.ft2font' extension
  clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers -DFREETYPE_BUILD_TYPE=system -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib_ft2font_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -I/Users/ahmedayman/Documents/CSCD01/matplotlib/.eggs/numpy-1.16.1-py3.7-macosx-10.13-x86_64.egg/numpy/core/include -Iextern/agg24-svn/include -I/usr/local/include -I/usr/include -I. -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.7.2_1/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c src/checkdep_freetype2.c -o build/temp.macosx-10.13-x86_64-3.7/src/checkdep_freetype2.o
  src/checkdep_freetype2.c:1:10: fatal error: 'ft2build.h' file not found
  #include &lt;ft2build.h&gt;
           ^~~~~~~~~~~~
  1 error generated.
  error: command 'clang' failed with exit status 1
  </code></pre>