From 76fe9bd5de642436ed9b2b0a7697a768f603cc94 Mon Sep 17 00:00:00 2001 From: Daniel Golle Date: Mon, 25 Nov 2024 22:36:18 +0100 Subject: [PATCH] assimp: add package Signed-off-by: Daniel Golle --- libs/assimp/Makefile | 49 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 libs/assimp/Makefile diff --git a/libs/assimp/Makefile b/libs/assimp/Makefile new file mode 100644 index 0000000..4f76298 --- /dev/null +++ b/libs/assimp/Makefile @@ -0,0 +1,49 @@ +include $(TOPDIR)/rules.mk + +PKG_NAME:=assimp +PKG_VERSION:=5.4.3 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=https://codeload.github.com/$(PKG_NAME)/$(PKG_NAME)/tar.gz/v$(PKG_VERSION)? +PKG_HASH:=66dfbaee288f2bc43172440a55d0235dfc7bf885dda6435c038e8000e79582cb + +PKG_MAINTAINER:=Daniel Golle +PKG_LICENSE:=BSD-3-Clause + +CMAKE_INSTALL:=1 +PKG_BUILD_FLAGS:=gc-sections lto + +include $(INCLUDE_DIR)/package.mk +include $(INCLUDE_DIR)/cmake.mk + +define Package/libassimp + SECTION:=libs + CATEGORY:=Libraries + SUBMENU:=Video + TITLE:=Open Asset Importer Library + URL:=https://github.com/assimp/assimp + DEPENDS:=+libstdcpp +zlib +endef + +define Package/libassimp/description +Open Asset Import Library is a library that loads various 3D file formats +into a shared, in-memory format. It supports more than 40 file formats +for import and a growing selection of file formats for export. +endef + +CMAKE_OPTIONS += \ + -DBUILD_SHARED_LIBS=ON + +define Build/InstallDev + $(call Build/InstallDev/cmake,$(1)) + $(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/assimp.pc + $(SED) 's,/usr/lib,$$$${prefix}/lib,g' $(1)/usr/lib/pkgconfig/assimp.pc +endef + +define Package/libassimp/install + $(INSTALL_DIR) $(1)/usr/lib + $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib +endef + +$(eval $(call BuildPackage,libassimp)) -- 2.30.2