Radix cross Linux

The main Radix cross Linux repository contains the build scripts of packages, which have the most complete and common functionality for desktop machines

452 Commits   2 Branches   1 Tag
Index: Makefile
===================================================================
--- Makefile	(nonexistent)
+++ Makefile	(revision 5)
@@ -0,0 +1,271 @@
+
+COMPONENT_TARGETS  = $(HARDWARE_S824L)
+COMPONENT_TARGETS += $(HARDWARE_VESNIN)
+COMPONENT_TARGETS += $(HARDWARE_TL2WK2)
+COMPONENT_TARGETS += $(HARDWARE_TL2SV2)
+
+NEED_ABS_PATH      = true
+COMPONENT_IS_3PP   = true
+
+CREATE_PPC32_PACKAGE = true
+
+
+include ../../../../build-system/constants.mk
+
+
+SOURCE_REQUIRES    = sources/packages/l/poppler
+
+REQUIRES           = X11/libs/poppler/23.02.0
+REQUIRES          += libs/lcms2/2.14-ppc32
+REQUIRES          += libs/libjpeg-turbo/2.1.2-ppc32
+REQUIRES          += libs/libpng/libpng16/1.6.37-ppc32
+REQUIRES          += libs/libtiff/4.3.0-ppc32
+REQUIRES          += libs/boost/1.77.0-ppc32
+REQUIRES          += libs/glib2/2.76.0-ppc32
+REQUIRES          += media/openjpeg2/2.5.0-ppc32
+REQUIRES          += net/nss/3.64-ppc32
+REQUIRES          += net/curl/7.75.0-ppc32
+REQUIRES          += X11/libs/qt5/5.15.8-ppc32
+REQUIRES          += X11/libs/gtk+3/3.24.37-ppc32
+REQUIRES          += X11/libs/cairo/1.17.8-ppc32
+
+# ======= __END_OF_REQUIRES__ =======
+
+
+version            = 23.02.0
+tar_xz_archive     = $(SRC_PACKAGE_PATH)/packages/l/poppler/poppler-$(version).tar.xz
+SRC_ARCHIVE        = $(tar_xz_archive)
+SRC_DIR            = $(TARGET_BUILD_DIR)/poppler-$(version)
+src_dir_name       = poppler-$(version)
+doc_dir_name       = poppler-$(version)
+src_done           = $(TARGET_BUILD_DIR)/.source_done
+
+PATCHES = PATCHES
+
+build_dir          = $(TARGET_BUILD_DIR)/build
+build_target       = $(TARGET_BUILD_DIR)/.build_done
+install_target     = $(TARGET_BUILD_DIR)/.install_done
+
+
+####### Targets
+
+PKG_GROUP = xlibs
+
+#
+# *PKG_NAME & *PKG_VERSION shouldn't be a reference to value.
+#
+POPPLER_32_PKG_NAME                = poppler-x32
+POPPLER_32_PKG_VERSION             = 23.02.0
+POPPLER_32_PKG_ARCH                = $(PKGARCH)
+POPPLER_32_PKG_DISTRO_NAME         = $(DISTRO_NAME)
+POPPLER_32_PKG_DISTRO_VERSION      = $(DISTRO_VERSION)
+POPPLER_32_PKG_GROUP               = $(PKG_GROUP)
+###                                 |---handy-ruler-------------------------------|
+POPPLER_32_PKG_SHORT_DESCRIPTION   = a library for rendering PDF documents
+POPPLER_32_PKG_URL                 = $(BUG_URL)
+POPPLER_32_PKG_LICENSE             = GPLv2
+POPPLER_32_PKG_DESCRIPTION_FILE    = $(TARGET_BUILD_DIR)/$(POPPLER_32_PKG_NAME)-pkg-description
+POPPLER_32_PKG_DESCRIPTION_FILE_IN = $(POPPLER_32_PKG_NAME)-pkg-description.in
+POPPLER_32_PKG_INSTALL_SCRIPT      = $(POPPLER_32_PKG_NAME)-pkg-install.sh
+
+POPPLER_32_PKG   = $(CURDIR)/$(TARGET_BUILD_DIR)/$(POPPLER_32_PKG_NAME)-package
+
+pkg_basename     = $(POPPLER_32_PKG_NAME)-$(POPPLER_32_PKG_VERSION)-$(POPPLER_32_PKG_ARCH)-$(POPPLER_32_PKG_DISTRO_NAME)-$(POPPLER_32_PKG_DISTRO_VERSION)
+
+pkg_archive      = $(TARGET_BUILD_DIR)/$(PKG_GROUP)/$(pkg_basename).$(pkg_arch_suffix)
+pkg_certificate  = $(call cert-name,$(pkg_archive))
+pkg_signature    = $(call sign-name,$(pkg_archive))
+pkg_description  = $(call desc-name,$(pkg_archive))
+products         = $(call pkg-files,$(pkg_archive))
+
+
+BUILD_TARGETS    = $(build_target)
+BUILD_TARGETS   += $(install_target)
+
+PRODUCT_TARGETS  = $(products)
+
+ROOTFS_TARGETS   = $(pkg_archive)
+
+
+include ../../../../build-system/core.mk
+
+
+env_sysroot = DESTDIR=$(POPPLER_32_PKG)
+
+
+ENABLE_GTK_DOCUMENTATION = no
+
+TARGET_BIN_RPATH = /lib$(MULTILIB_PPC32_SUFFIX):/usr/lib$(MULTILIB_PPC32_SUFFIX)
+TARGET_LIB_RPATH = /lib$(MULTILIB_PPC32_SUFFIX):/usr/lib$(MULTILIB_PPC32_SUFFIX):/usr/lib/../lib$(MULTILIB_PPC32_SUFFIX)
+
+suppress-warnings   = -Wno-use-after-free -Wno-unused-but-set-variable -Wno-format -Wno-format-security
+suppress-warnings  += -Wno-maybe-uninitialized -Wno-cast-align -Wno-stringop-overflow -Wno-psabi
+suppress-warnings  += -Wno-deprecated-declarations -Wno-free-nonheap-object
+
+configure_switches  = -DCMAKE_BUILD_TYPE='Release'
+
+configure_switches += -DCMAKE_C_COMPILER='$(CROSS_PREFIX)gcc'
+configure_switches += -DCMAKE_LINKER='$(CROSS_PREFIX)ld'
+configure_switches += -DCMAKE_AR='$(CROSS_PREFIX)ar'
+configure_switches += -DCMAKE_NM='$(CROSS_PREFIX)nm'
+configure_switches += -DCMAKE_RANLIB='$(CROSS_PREFIX)ranlib'
+configure_switches += -DCMAKE_OBJCOPY='$(CROSS_PREFIX)objcopy'
+configure_switches += -DCMAKE_OBJDUMP='$(CROSS_PREFIX)objdump'
+configure_switches += -DCMAKE_STRIP='$(CROSS_PREFIX)strip'
+
+configure_switches += -DCMAKE_C_FLAGS='--sysroot=$(TARGET_DEST_DIR) -m32 $(CFLAGS) $(ARCH_FLAGS) $(ARCH_DEFS) $(HW_FLAGS) $(suppress-warnings)'
+configure_switches += -DCMAKE_CXX_FLAGS='--sysroot=$(TARGET_DEST_DIR) -m32 $(CFLAGS) $(ARCH_FLAGS) $(ARCH_DEFS) $(HW_FLAGS) $(suppress-warnings)'
+
+configure_switches += -DCMAKE_EXE_LINKER_FLAGS='--sysroot=$(TARGET_DEST_DIR) -m32 -Wl,-rpath,$(TARGET_BIN_RPATH) -L$(TARGET_DEST_DIR)/lib$(MULTILIB_PPC32_SUFFIX) -L$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX) -lstdc++'
+configure_switches += -DCMAKE_MODULE_LINKER_FLAGS='--sysroot=$(TARGET_DEST_DIR) -m32 -Wl,-rpath,$(TARGET_LIB_RPATH) -L$(TARGET_DEST_DIR)/lib$(MULTILIB_PPC32_SUFFIX) -L$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX) -lstdc++'
+configure_switches += -DCMAKE_SHARED_LINKER_FLAGS='--sysroot=$(TARGET_DEST_DIR) -m32 -Wl,-rpath,$(TARGET_LIB_RPATH) -L$(TARGET_DEST_DIR)/lib$(MULTILIB_PPC32_SUFFIX) -L$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX) -lstdc++'
+
+configure_switches += -DCMAKE_INSTALL_PREFIX=/usr
+
+configure_switches += -DCMAKE_INSTALL_DOCDIR='/usr/share/doc/$(doc_dir_name)'
+configure_switches += -DCMAKE_INSTALL_INFODIR='/usr/share/info'
+configure_switches += -DCMAKE_INSTALL_MANDIR='/usr/share/man'
+
+configure_switches += -DCMAKE_INSTALL_SYSCONFDIR='etc'
+configure_switches += -DCMAKE_INSTALL_BINDIR='bin/32'
+configure_switches += -DCMAKE_INSTALL_LIBDIR='lib$(MULTILIB_PPC32_SUFFIX)'
+
+configure_switches += -DCMAKE_CROSSCOMPILING=True
+
+configure_switches += -DBUILD_SHARED_LIBS=ON
+
+configure_switches += -DBUILD_GTK_TESTS=OFF
+configure_switches += -DBUILD_QT5_TESTS=OFF
+configure_switches += -DBUILD_QT6_TESTS=OFF
+configure_switches += -DBUILD_CPP_TESTS=OFF
+configure_switches += -DBUILD_MANUAL_TESTS=OFF
+configure_switches += -DENABLE_BOOST=ON
+configure_switches += -DENABLE_UTILS=ON
+configure_switches += -DENABLE_CPP=ON
+configure_switches += -DENABLE_GLIB=ON
+configure_switches += -DENABLE_GOBJECT_INTROSPECTION=OFF
+configure_switches += -DENABLE_LIBOPENJPEG=openjpeg2
+configure_switches += -DENABLE_CMS=lcms2
+configure_switches += -DENABLE_LIBCURL=ON
+configure_switches += -DENABLE_ZLIB=ON
+configure_switches += -DENABLE_QT5=ON
+configure_switches += -DENABLE_QT6=OFF
+
+configure_switches += -DENABLE_UNSTABLE_API_ABI_HEADERS=ON
+configure_switches += -DTESTDATADIR=$(CURDIR)/$(SRC_DIR)/test
+
+configure_switches += -DENABLE_GTK_DOC=False
+
+configure_switches += -DFREETYPE_INCLUDE_DIR_freetype2=$(TARGET_DEST_DIR)/usr/include/freetype2
+configure_switches += -DFREETYPE_INCLUDE_DIR_ft2build=$(TARGET_DEST_DIR)/usr/include/freetype2
+configure_switches += -DFREETYPE_LIBRARY_RELEASE=$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/libfreetype.so
+
+configure_switches += -DFontconfig_INCLUDE_DIR=$(TARGET_DEST_DIR)/usr/include
+configure_switches += -DFontconfig_LIBRARY=$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/libfontconfig.so
+
+configure_switches += -DJPEG_INCLUDE_DIR=$(TARGET_DEST_DIR)/usr/include
+configure_switches += -DJPEG_LIBRARY_RELEASE=$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/libjpeg.so
+
+configure_switches += -DPNG_LIBRARY_RELEASE=$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/libpng.so
+configure_switches += -DPNG_PNG_INCLUDE_DIR=$(TARGET_DEST_DIR)/usr/include
+
+configure_switches += -DTIFF_INCLUDE_DIR=$(TARGET_DEST_DIR)/usr/include
+configure_switches += -DTIFF_LIBRARY_RELEASE=$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/libtiff.so
+
+configure_switches += -DZLIB_INCLUDE_DIR=$(TARGET_DEST_DIR)/usr/include
+configure_switches += -DZLIB_LIBRARY_RELEASE=$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/libz.so
+
+configure_switches += -DBoost_DIR=$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/cmake/Boost-1.77.0
+configure_switches += -DBoost_INCLUDE_DIR=$(TARGET_DEST_DIR)/usr/include/boost
+
+configure_switches += -DLCMS2_INCLUDE_DIR=$(TARGET_DEST_DIR)/usr/include
+configure_switches += -DLCMS2_LIBRARIES=$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/liblcms2.so
+
+configure_switches += -DOpenJPEG_DIR=$(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/openjpeg-2.5
+
+
+####### Dependencies
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+	$(UNPACK_SRC_ARCHIVE)
+	$(APPLY_PATCHES)
+	@touch $(SRC_DIR)/test/test-poppler.c
+	# ======= Patch CMakeLists.txt for finding Qt5 modules =======
+	@( cd $(SRC_DIR) ; \
+	   sed -i '/^if (ENABLE_QT5)/a \
+	  Set(Qt5Core_DIR $(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/cmake/Qt5Core)\
+	  Set(Qt5Gui_DIR $(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/cmake/Qt5Gui)\
+	  Set(Qt5Xml_DIR $(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/cmake/Qt5Xml)\
+	  Set(Qt5Widgets_DIR $(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/cmake/Qt5Widgets)\
+	  Set(Qt5Test_DIR $(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/cmake/Qt5Test)\
+	  LINK_DIRECTORIES($(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX))\
+	' CMakeLists.txt ; \
+	 )
+	@( cd $(SRC_DIR)/qt5 ; \
+	   sed -i 's,CMAKE_AUTOMOC ON,CMAKE_AUTOMOC OFF,' CMakeLists.txt ; \
+	 )
+	@touch $@
+
+$(build_target): $(src_done)
+	# ======= Build Poppler =======
+	@mkdir -p $(build_dir)
+	@( cd $(build_dir) ; \
+	   $(BUILD_ENVIRONMENT) cmake $(configure_switches) ../$(src_dir_name) ; \
+	 )
+	# ======= Patch AutogenInfo.json files for finding QT_MOC_EXECUTABLE =======
+	@( cd $(build_dir) ; \
+	   for file in `find . -type f -name 'AutogenInfo.json' -print` ; do \
+	     sed -i '/QT_MOC_EXECUTABLE/s,bin/moc,bin/$(TARGET32)-moc,' $${file} ; \
+	   done ; \
+	 )
+	@( cd $(build_dir) ; \
+	   $(BUILD_ENVIRONMENT) $(MAKE) ; \
+	 )
+	@touch $@
+
+$(install_target): $(build_target)
+	@mkdir -p $(POPPLER_32_PKG)
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) $(MAKE) -j1 install $(env_sysroot)
+	@mkdir -p $(POPPLER_32_PKG)/usr/bin/32
+	@( cd $(POPPLER_32_PKG)/usr/bin ; \
+	   find . -type f | xargs mv -t 32 ; \
+	 )
+	@rm -rf $(POPPLER_32_PKG)/usr/include
+	@rm -rf $(POPPLER_32_PKG)/usr/share
+	# ======= Install the same to $(TARGET_DEST_DIR) =======
+	$(call install-into-devenv, $(POPPLER_32_PKG))
+	# ======= tune pkg-config *.pc search path to the target destination for development =======
+	@( cd $(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX)/pkgconfig ; \
+	   sed -i "s,/usr,$(TARGET_DEST_DIR)/usr,g" poppler-cpp.pc poppler-glib.pc  \
+	                                            poppler-qt5.pc poppler.pc     ; \
+	 )
+	# ======= Strip binaries =======
+	@( cd $(POPPLER_32_PKG) ; \
+	   find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs $(STRIP) --strip-unneeded 2> /dev/null ; \
+	   find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs $(STRIP) --strip-unneeded 2> /dev/null ; \
+	 )
+	@touch $@
+
+$(POPPLER_32_PKG_DESCRIPTION_FILE): $(POPPLER_32_PKG_DESCRIPTION_FILE_IN)
+	@cat $< | $(SED) -e "s/@VERSION@/$(version)/g" > $@
+
+$(pkg_certificate) : $(pkg_archive) ;
+$(pkg_signature)   : $(pkg_archive) ;
+$(pkg_description) : $(pkg_archive) ;
+
+$(pkg_archive): $(install_target) $(POPPLER_32_PKG_DESCRIPTION_FILE) $(POPPLER_32_PKG_INSTALL_SCRIPT)
+	@cp $(POPPLER_32_PKG_DESCRIPTION_FILE) $(POPPLER_32_PKG)/.DESCRIPTION
+	@cp $(POPPLER_32_PKG_INSTALL_SCRIPT) $(POPPLER_32_PKG)/.INSTALL
+	@$(BUILD_PKG_REQUIRES) $(POPPLER_32_PKG)/.REQUIRES
+	@echo "pkgname=$(POPPLER_32_PKG_NAME)"                            >  $(POPPLER_32_PKG)/.PKGINFO ; \
+	 echo "pkgver=$(POPPLER_32_PKG_VERSION)"                          >> $(POPPLER_32_PKG)/.PKGINFO ; \
+	 echo "arch=$(POPPLER_32_PKG_ARCH)"                               >> $(POPPLER_32_PKG)/.PKGINFO ; \
+	 echo "distroname=$(POPPLER_32_PKG_DISTRO_NAME)"                  >> $(POPPLER_32_PKG)/.PKGINFO ; \
+	 echo "distrover=$(POPPLER_32_PKG_DISTRO_VERSION)"                >> $(POPPLER_32_PKG)/.PKGINFO ; \
+	 echo "group=$(POPPLER_32_PKG_GROUP)"                             >> $(POPPLER_32_PKG)/.PKGINFO ; \
+	 echo "short_description=\"$(POPPLER_32_PKG_SHORT_DESCRIPTION)\"" >> $(POPPLER_32_PKG)/.PKGINFO ; \
+	 echo "url=$(POPPLER_32_PKG_URL)"                                 >> $(POPPLER_32_PKG)/.PKGINFO ; \
+	 echo "license=$(POPPLER_32_PKG_LICENSE)"                         >> $(POPPLER_32_PKG)/.PKGINFO
+	@$(PSEUDO) sh -c "cd $(POPPLER_32_PKG) && \
+	                  chown -R root:root . && \
+	                  $(MAKE_PACKAGE) -J --linkadd=yes $(GNUPG_OPTIONS) -m -d .. ."
Index: PATCHES
===================================================================
Index: poppler-x32-pkg-description.in
===================================================================
--- poppler-x32-pkg-description.in	(nonexistent)
+++ poppler-x32-pkg-description.in	(revision 5)
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description.  Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in.  You must
+# make exactly 11 lines for the formatting to be correct.  It's also
+# customary to leave one space after the ':'.
+
+           |-----handy-ruler------------------------------------------------------|
+poppler-x32: poppler-x32 @VERSION@ (a library for rendering PDF documents)
+poppler-x32:
+poppler-x32: Poppler is a library based on the xpdf PDF viewer developed by
+poppler-x32: Derek Noonburg of Glyph and Cog, LLC. Since xpdf does not provide
+poppler-x32: a shared library, whenever a flaw was found potentially dozens of
+poppler-x32: applications incorporating code from xpdf would have to be patched.
+poppler-x32: By providing a centralized PDF library this duplicated effort will
+poppler-x32: be eliminated.
+poppler-x32:
+poppler-x32: Homepage: https://poppler.freedesktop.org
+poppler-x32:
Index: poppler-x32-pkg-install.sh
===================================================================
--- poppler-x32-pkg-install.sh	(nonexistent)
+++ poppler-x32-pkg-install.sh	(revision 5)
@@ -0,0 +1,39 @@
+#!/bin/sh
+
+# arg 1:  the new package version
+pre_install() {
+  /bin/true
+}
+
+# arg 1:  the new package version
+post_install() {
+  /bin/true
+}
+
+# arg 1:  the new package version
+# arg 2:  the old package version
+pre_update() {
+  /bin/true
+}
+
+# arg 1:  the new package version
+# arg 2:  the old package version
+post_update() {
+  post_install
+}
+
+# arg 1:  the old package version
+pre_remove() {
+  /bin/true
+}
+
+# arg 1:  the old package version
+post_remove() {
+  /bin/true
+}
+
+
+operation=$1
+shift
+
+$operation $*

Property changes on: poppler-x32-pkg-install.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: .
===================================================================
--- .	(nonexistent)
+++ .	(revision 5)

Property changes on: .
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,73 ##
+
+# install dir
+dist
+
+# Target build dirs
+.a1x-newlib
+.a2x-newlib
+.at91sam7s-newlib
+
+.build-machine
+
+.a1x-glibc
+.a2x-glibc
+.h3-glibc
+.h5-glibc
+.i586-glibc
+.i686-glibc
+.imx6-glibc
+.jz47xx-glibc
+.makefile
+.am335x-glibc
+.omap543x-glibc
+.p5600-glibc
+.power8-glibc
+.power8le-glibc
+.power9-glibc
+.power9le-glibc
+.m1000-glibc
+.riscv64-glibc
+.rk328x-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.dist
+.rootfs
+
+# src & hw requires
+.src_requires
+.src_requires_depend
+.requires
+.requires_depend
+
+# Tarballs
+*.gz
+*.bz2
+*.lz
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Descriptions
+*.dsc
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# backup copies
+*~