libjpeg-turbo: enable static library
authorOskari Rauta <oskari.rauta@gmail.com>
Sun, 12 Mar 2023 16:42:26 +0000 (18:42 +0200)
committerRosen Penev <rosenp@gmail.com>
Tue, 14 Mar 2023 22:44:24 +0000 (15:44 -0700)
Allow build of libjpeg as a static library as well;
one is provided for libpng and possibly for other
formats as well.

Signed-off-by: Oskari Rauta <oskari.rauta@gmail.com>
libs/libjpeg-turbo/Makefile

index ecf6a1f94e7a8c6b1944883997b6dab40ed82396..7aed20d332a42f991555b6909c7ea2859783451d 100644 (file)
@@ -2,7 +2,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=libjpeg-turbo
 PKG_VERSION:=2.1.4
-PKG_RELEASE:=$(AUTORELEASE)
+PKG_RELEASE:=2
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=@SF/$(PKG_NAME)
@@ -50,7 +50,7 @@ endef
 
 CMAKE_OPTIONS += \
        -DENABLE_SHARED=ON \
-       -DENABLE_STATIC=OFF \
+       -DENABLE_STATIC=ON \
        -DREQUIRE_SIMD=OFF \
        -DWITH_12BIT=OFF \
        -DWITH_ARITH_DEC=OFF \
@@ -73,6 +73,7 @@ define Build/InstallDev
        $(CP) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/
        $(INSTALL_DIR) $(1)/usr/lib
        $(CP) $(PKG_INSTALL_DIR)/usr/lib/libjpeg.so* $(1)/usr/lib/
+       $(CP) $(PKG_INSTALL_DIR)/usr/lib/libjpeg.a $(1)/usr/lib/
        $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
        $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/*.pc $(1)/usr/lib/pkgconfig/
        $(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/libjpeg.pc