需求:
- libjpeg.so.8: cannot open shared object file: No such file or directory
- 服务用到 libjpeg 但是centos 没有libjepg9 只有 libjped-turbo
进程:
- yum 不能直接安装那就只能自己编译了
- 进入下载包地址 Independent JPEG Group
- 下载对应的tar 包 wget http://www.ijg.org/files/jpegsrc.v8c.tar.gz
- 解压 tar zxvf jpegsrc.v8c.tar.gz && cd jpeg-8c/
- 编译 ./configure --enable-shared && make && make install
拓展:
- cinfigure 的时候 --enable-shared 不能漏
- --enable-shared 会生成以 .so 结尾 或者 以 .so.*** 结尾的文件 动态连接库
- --enable-static 会生成以 .a 为结尾的文件 静态链接库