Install sqlite3 on ubuntu by compiling from source code

  1. prepare build tools if tools not ready
    1
    sudo apt-get install build-essential
  2. download source code package from https://www.sqlite.org/download.html
    1
    curl -O https://www.sqlite.org/snapshot/sqlite-snapshot-202003121754.tar.gz
  3. unzip and enter the dir
    1
    2
    tar xvzf sqlite...tar.gz
    cd sqlite...
  4. compile, build and install
    1
    2
    3
    4
    ./configure
    make
    #if failed, try "make clean" and run "make" again
    sudo make install

Reference from:

  1. https://stackoverflow.com/questions/19816275/no-acceptable-c-compiler-found-in-path-when-installing-python
  2. INSTALL doc in the package
  3. SQLite 安装