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

383 Commits   1 Branch   1 Tag
Index: 2.4.58/Makefile
===================================================================
--- 2.4.58/Makefile	(nonexistent)
+++ 2.4.58/Makefile	(revision 5)
@@ -0,0 +1,405 @@
+
+COMPONENT_TARGETS  = $(HARDWARE_INTEL_PC32)
+COMPONENT_TARGETS += $(HARDWARE_INTEL_PC64)
+COMPONENT_TARGETS += $(HARDWARE_EBOX_3350DX2)
+COMPONENT_TARGETS += $(HARDWARE_CB1X)
+COMPONENT_TARGETS += $(HARDWARE_CB2X)
+COMPONENT_TARGETS += $(HARDWARE_CB3X)
+COMPONENT_TARGETS += $(HARDWARE_ORANGE_PP2E)
+COMPONENT_TARGETS += $(HARDWARE_NANOPI_NEO)
+COMPONENT_TARGETS += $(HARDWARE_ORANGE_PP)
+COMPONENT_TARGETS += $(HARDWARE_ORANGE_PL2)
+COMPONENT_TARGETS += $(HARDWARE_WECHIP_TX6)
+COMPONENT_TARGETS += $(HARDWARE_FFRK3288)
+COMPONENT_TARGETS += $(HARDWARE_POIN2)
+COMPONENT_TARGETS += $(HARDWARE_RK3328_CC)
+COMPONENT_TARGETS += $(HARDWARE_KHADAS_EDGE)
+COMPONENT_TARGETS += $(HARDWARE_LEEZ_P710)
+COMPONENT_TARGETS += $(HARDWARE_M201)
+COMPONENT_TARGETS += $(HARDWARE_MXV)
+COMPONENT_TARGETS += $(HARDWARE_P201)
+COMPONENT_TARGETS += $(HARDWARE_NEXBOX_A95X)
+COMPONENT_TARGETS += $(HARDWARE_ODROID_C2)
+COMPONENT_TARGETS += $(HARDWARE_P212)
+COMPONENT_TARGETS += $(HARDWARE_KHADAS_VIM)
+COMPONENT_TARGETS += $(HARDWARE_Q201)
+COMPONENT_TARGETS += $(HARDWARE_ENYBOX_X2)
+COMPONENT_TARGETS += $(HARDWARE_KHADAS_VIM2)
+COMPONENT_TARGETS += $(HARDWARE_NIT6Q)
+COMPONENT_TARGETS += $(HARDWARE_OKMX6DL_C)
+COMPONENT_TARGETS += $(HARDWARE_OKMX6Q_C)
+COMPONENT_TARGETS += $(HARDWARE_BONE_BLACK)
+COMPONENT_TARGETS += $(HARDWARE_OMAP5UEVM)
+COMPONENT_TARGETS += $(HARDWARE_DRA7XXEVM)
+COMPONENT_TARGETS += $(HARDWARE_CI20)
+COMPONENT_TARGETS += $(HARDWARE_BAIKAL_T1)
+COMPONENT_TARGETS += $(HARDWARE_BAIKAL_M1)
+COMPONENT_TARGETS += $(HARDWARE_S824L)
+COMPONENT_TARGETS += $(HARDWARE_VESNIN)
+COMPONENT_TARGETS += $(HARDWARE_S824L_LSB)
+COMPONENT_TARGETS += $(HARDWARE_VESNIN_LSB)
+COMPONENT_TARGETS += $(HARDWARE_TL2WK2)
+COMPONENT_TARGETS += $(HARDWARE_TL2SV2)
+COMPONENT_TARGETS += $(HARDWARE_TL2WK2_LSB)
+COMPONENT_TARGETS += $(HARDWARE_TL2SV2_LSB)
+COMPONENT_TARGETS += $(HARDWARE_SIFIVE_U740)
+
+
+NEED_ABS_PATH      = true
+COMPONENT_IS_3PP   = true
+
+
+include ../../../build-system/constants.mk
+
+
+SOURCE_REQUIRES    = sources/packages/n/openldap
+
+REQUIRES           = net/openssl/1.1.1r
+REQUIRES          += net/tcp_wrappers/7.6
+REQUIRES          += app/util-linux/2.38.1
+REQUIRES          += app/db/18.1.40
+REQUIRES          += libs/libiodbc/3.52.14
+REQUIRES          += dev/libtool/2.4.6
+REQUIRES          += dev/perl/5.36.0
+REQUIRES          += env/cyrus-sasl/2.1.27
+
+# ======= __END_OF_REQUIRES__ =======
+
+
+version            = 2.4.58
+tar_gz_archive     = $(SRC_PACKAGE_PATH)/packages/n/openldap/openldap-$(version).tgz
+SRC_ARCHIVE        = $(tar_gz_archive)
+SRC_DIR            = $(TARGET_BUILD_DIR)/openldap-$(version)
+src_dir_name       = openldap-$(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 = net
+
+#
+# *PKG_NAME & *PKG_VERSION shouldn't be a reference to value.
+#
+OPENLDAP_PKG_NAME                = openldap
+OPENLDAP_PKG_VERSION             = 2.4.58
+OPENLDAP_PKG_ARCH                = $(PKGARCH)
+OPENLDAP_PKG_DISTRO_NAME         = $(DISTRO_NAME)
+OPENLDAP_PKG_DISTRO_VERSION      = $(DISTRO_VERSION)
+OPENLDAP_PKG_GROUP               = $(PKG_GROUP)
+###                               |---handy-ruler-------------------------------|
+OPENLDAP_PKG_SHORT_DESCRIPTION   = Lightweight Directory Access Protocol
+OPENLDAP_PKG_URL                 = $(BUG_URL)
+OPENLDAP_PKG_LICENSE             = custom
+OPENLDAP_PKG_DESCRIPTION_FILE    = $(TARGET_BUILD_DIR)/$(OPENLDAP_PKG_NAME)-pkg-description
+OPENLDAP_PKG_DESCRIPTION_FILE_IN = $(OPENLDAP_PKG_NAME)-pkg-description.in
+OPENLDAP_PKG_INSTALL_SCRIPT      = $(OPENLDAP_PKG_NAME)-pkg-install.sh
+
+OPENLDAP_PKG     = $(CURDIR)/$(TARGET_BUILD_DIR)/$(OPENLDAP_PKG_NAME)-package
+
+pkg_basename     = $(OPENLDAP_PKG_NAME)-$(OPENLDAP_PKG_VERSION)-$(OPENLDAP_PKG_ARCH)-$(OPENLDAP_PKG_DISTRO_NAME)-$(OPENLDAP_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=$(OPENLDAP_PKG)
+
+
+extra_configure_switches  = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --docdir=/usr/share/doc/$(src_dir_name)
+extra_configure_switches += --infodir=/usr/share/info
+extra_configure_switches += --mandir=/usr/share/man
+extra_configure_switches += --sysconfdir=/etc
+extra_configure_switches += --localstatedir=/var
+
+extra_configure_switches += --enable-debug
+extra_configure_switches += --enable-dynamic
+extra_configure_switches += --enable-syslog
+extra_configure_switches += --enable-proctitle
+extra_configure_switches += --enable-ipv6
+extra_configure_switches += --enable-local
+
+extra_configure_switches += --enable-slapd
+extra_configure_switches += --enable-dynacl
+extra_configure_switches += --enable-aci
+extra_configure_switches += --enable-cleartext
+extra_configure_switches += --enable-crypt
+extra_configure_switches += --enable-lmpasswd
+extra_configure_switches += --enable-spasswd
+extra_configure_switches += --enable-modules
+extra_configure_switches += --enable-rewrite
+extra_configure_switches += --enable-rlookups
+extra_configure_switches += --enable-slapi
+extra_configure_switches += --disable-slp
+extra_configure_switches += --enable-wrappers
+
+extra_configure_switches += --enable-backends=mod
+extra_configure_switches += --enable-bdb=yes
+extra_configure_switches += --enable-hdb=yes
+extra_configure_switches += --enable-ldap=yes
+extra_configure_switches += --enable-mdb=yes
+extra_configure_switches += --enable-monitor=yes
+extra_configure_switches += --enable-perl=yes
+extra_configure_switches += --disable-ndb
+
+extra_configure_switches += --enable-overlays=mod
+
+extra_configure_switches += --with-cyrus-sasl
+extra_configure_switches += --without-fetch
+extra_configure_switches += --with-threads
+extra_configure_switches += --with-pic
+extra_configure_switches += --with-tls
+
+extra_configure_switches += --with-yielding-select=yes
+
+ifeq ($(__ENABLE_STATIC__),yes)
+extra_configure_switches += --enable-static=yes
+else
+extra_configure_switches += --enable-static=no
+endif
+extra_configure_switches += --enable-shared=yes
+
+
+extra_DB_environment  = ol_cv_bdb_compat=yes
+extra_DB_environment += ol_cv_berkeley_db_thread=yes
+
+
+LDFLAGS += -Wl,-rpath=/lib$(LIBSUFFIX):/usr/lib$(LIBSUFFIX):/usr/lib/../lib$(LIBSUFFIX)
+
+
+TARGET_BIN_RPATH = /lib$(LIBSUFFIX):/usr/lib$(LIBSUFFIX)
+TARGET_LIB_RPATH = /lib$(LIBSUFFIX):/usr/lib$(LIBSUFFIX):/usr/lib/../lib$(LIBSUFFIX)
+
+
+####### Dependencies
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+	$(UNPACK_SRC_ARCHIVE)
+	$(APPLY_PATCHES)
+	# ======= Change the location of run directory into /var/run/openldap: =======
+	@sed -i -e 's|%LOCALSTATEDIR%/run/|/var/run/openldap/|' $(SRC_DIR)/servers/slapd/slapd.*
+	# ======= Change the location of ldapi socket into /var/run/openldap: =======
+	@sed -i -e 's|\(#define LDAPI_SOCK\).*|\1 "/var/run/openldap/ldapi"|' $(SRC_DIR)/include/ldap_defaults.h
+	# ======= Change the default OpenLDAP database directory: =======
+	@sed -i -e 's|openldap-data|lib/openldap|' \
+	   $(SRC_DIR)/servers/slapd/slapd.*     \
+	   $(SRC_DIR)/include/ldap_defaults.h   \
+	   $(SRC_DIR)/servers/slapd/Makefile.in
+	# ======= Fix man pages: =======
+	@sed -i "s/openldap\\\-data/lib\/openldap/g" \
+	   $(SRC_DIR)/doc/man/man5/slapd-config.5 \
+	   $(SRC_DIR)/doc/man/man5/slapd-bdb.5    \
+	   $(SRC_DIR)/doc/man/man5/slapd-mdb.5    \
+	   $(SRC_DIR)/doc/man/man5/slapd.conf.5
+	@touch $@
+
+$(build_target): $(src_done)
+	@mkdir -p $(build_dir)
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) $(extra_DB_environment) STRIP= ../$(src_dir_name)/configure \
+	  --prefix=/usr               \
+	  --exec-prefix=/usr          \
+	  --build=$(BUILD)            \
+	  --host=$(TARGET)            \
+	  $(extra_configure_switches)
+	@( cd $(build_dir) ; \
+	   sed -i "s,#define NEED_MEMCMP_REPLACEMENT 1,/* #undef NEED_MEMCMP_REPLACEMENT */," include/portable.h ; \
+	   find . -type f -name Makefile -exec \
+	     sed -i 's,STRIP = -s,STRIP =,g' {} \; ; \
+	   find . -type f -name Makefile -exec \
+	     sed -i -e 's,-I$(BUILDSYSTEM),-I$(TARGET_DEST_DIR),g' \
+	            -e 's,-L$(BUILDSYSTEM),-L$(TARGET_DEST_DIR),g' \
+	            -e 's,\,$(BUILDSYSTEM),\,$(TARGET_DEST_DIR),g' \
+	            -e 's,\"$(BUILDSYSTEM),\"$(TARGET_DEST_DIR),g' {} \; ;\
+	 )
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) $(MAKE)
+	@touch $@
+
+$(install_target): $(build_target)
+	@mkdir -p $(OPENLDAP_PKG)
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) $(MAKE) -j1 install $(env_sysroot)
+	@chmod 0755 $(OPENLDAP_PKG)/usr/lib$(LIBSUFFIX)/lib*.la
+	@chmod 0755 $(OPENLDAP_PKG)/usr/lib$(LIBSUFFIX)/lib*.so.?.*
+	@rm -rf $(OPENLDAP_PKG)/var/run
+	@rm  -f $(OPENLDAP_PKG)/etc/openldap/*.default
+	@mv $(OPENLDAP_PKG)/etc/openldap/ldap.conf $(OPENLDAP_PKG)/etc/openldap/ldap.conf.new
+	@echo ""                                                                         >> $(OPENLDAP_PKG)/etc/openldap/ldap.conf.new
+	@echo "# In order to avoid problems with self-signed certificates using TLS:"    >> $(OPENLDAP_PKG)/etc/openldap/ldap.conf.new
+	@echo "# 'TLS certificate verification: Error, self signed certificate'"         >> $(OPENLDAP_PKG)/etc/openldap/ldap.conf.new
+	@echo "# See also 'man ldap.conf' or http://www.openldap.org/doc/admin/tls.html" >> $(OPENLDAP_PKG)/etc/openldap/ldap.conf.new
+	@echo "TLS_REQCERT allow"                                                        >> $(OPENLDAP_PKG)/etc/openldap/ldap.conf.new
+	@echo ""                                                                         >> $(OPENLDAP_PKG)/etc/openldap/ldap.conf.new
+	# ======= Move other config files to .new: =======
+	@mv $(OPENLDAP_PKG)/etc/openldap/slapd.conf $(OPENLDAP_PKG)/etc/openldap/slapd.conf.new
+	@mv $(OPENLDAP_PKG)/etc/openldap/slapd.ldif $(OPENLDAP_PKG)/etc/openldap/slapd.ldif.new
+	# ======= Create a symlink for slapd in /usr/sbin: =======
+	@if [ ! -x $(OPENLDAP_PKG)/usr/sbin/slapd ]; then \
+	   ( cd $(OPENLDAP_PKG)/usr/sbin ; ln -sf ../libexec/slapd slapd ) ; \
+	 fi
+	# ======= Create OpenLDAP certificates directory: =======
+	@mkdir -p $(OPENLDAP_PKG)/etc/openldap/certs
+	# ======= Copy rc.openldap: =======
+	@mkdir -p $(OPENLDAP_PKG)/etc/rc.d
+	@cat $(CURDIR)/scripts/rc.openldap > $(OPENLDAP_PKG)/etc/rc.d/rc.openldap.new
+	# ======= Copy slapd default file: =======
+	@mkdir -p $(OPENLDAP_PKG)/etc/default
+	@cat $(CURDIR)/scripts/slapd > $(OPENLDAP_PKG)/etc/default/slapd.new
+	# ======= Install Documentation =======
+	@if [ -d $(OPENLDAP_PKG)/usr/share/man ]; then \
+	  ( cd $(OPENLDAP_PKG)/usr/share/man ; \
+	    for manpagedir in `find . -type d -name "man*"` ; do \
+	      ( cd $$manpagedir ; \
+	        for eachpage in `find . -type l -maxdepth 1` ; do \
+	          ln -s `readlink $$eachpage`.gz $$eachpage.gz ; \
+	          rm $$eachpage ; \
+	        done ; \
+	        gzip -9 *.? ; \
+	      ) \
+	    done \
+	  ) \
+	 fi
+	@mkdir -p $(OPENLDAP_PKG)/usr/doc/$(src_dir_name)
+	@cp -a $(SRC_DIR)/ANNOUNCEMENT $(SRC_DIR)/COPYRIGHT $(SRC_DIR)/LICENSE \
+	       $(OPENLDAP_PKG)/usr/doc/$(src_dir_name)
+	@mkdir -p $(OPENLDAP_PKG)/usr/share/doc/$(src_dir_name)/{admin,perl}
+	@( cd $(SRC_DIR) ; \
+	   cp -a ANNOUNCEMENT COPYRIGHT INSTALL LICENSE README \
+	         $(OPENLDAP_PKG)/usr/share/doc/$(src_dir_name) ; \
+	 )
+	@( cd $(SRC_DIR) ; \
+	   if [ -r CHANGES ]; then \
+	     DOCSDIR=`echo $(OPENLDAP_PKG)/usr/share/doc/$(src_dir_name)` ; \
+	     cat CHANGES | head -n 1000 > $$DOCSDIR/CHANGES ; \
+	     touch -r CHANGES $$DOCSDIR/CHANGES ; \
+	   fi \
+	 )
+	# ======= Include monitor backend README =======
+	@cp -a \
+	   $(SRC_DIR)/servers/slapd/back-monitor/README \
+	   $(OPENLDAP_PKG)/usr/share/doc/$(src_dir_name)/README.back-monitor
+	# ======= Include Perl backend README
+	@cp -a \
+	   $(SRC_DIR)/servers/slapd/back-perl/README \
+	   $(OPENLDAP_PKG)/usr/share/doc/$(src_dir_name)/perl
+	# ======= Include Perl backend sample file =======
+	@cp -a \
+	   $(SRC_DIR)/servers/slapd/back-perl/SampleLDAP.pm \
+	   $(OPENLDAP_PKG)/usr/share/doc/$(src_dir_name)/perl
+	# ======= Include OpenLDAP documentation =======
+	@cp -a \
+	   $(SRC_DIR)/doc/guide/admin/*.{png,html} \
+	   $(OPENLDAP_PKG)/usr/share/doc/$(src_dir_name)/admin
+	# ======= remove toolchain path from target libtool *.la files =======
+	@( cd $(OPENLDAP_PKG)/usr/lib$(LIBSUFFIX) ; \
+	   sed -i "s,$(TARGET_DEST_DIR),,g" liblber.la libldap.la libldap_r.la libslapi.la ; \
+	 )
+	@( cd $(OPENLDAP_PKG)/usr/libexec/openldap ; \
+	   sed -i "s,$(TARGET_DEST_DIR),,g" accesslog.la  auditlog.la     back_dnssrv.la  back_meta.la  \
+	                                    back_null.la  back_passwd.la  back_relay.la   back_shell.la \
+	                                    back_sock.la  back_sql.la     collect.la      constraint.la \
+	                                    dds.la        deref.la        dyngroup.la     dynlist.la    \
+	                                    memberof.la   pcache.la       ppolicy.la      refint.la     \
+	                                    retcode.la    rwm.la          seqmod.la       sssvlv.la     \
+	                                    syncprov.la   translucent.la  unique.la       valsort.la  ; \
+	 )
+	# ======= Install the same to $(TARGET_DEST_DIR) =======
+	$(call install-into-devenv, $(OPENLDAP_PKG))
+	# ======= tune libtool *.la search path to the target destination for development =======
+	@( cd $(TARGET_DEST_DIR)/usr/lib$(LIBSUFFIX) ; \
+	   sed -i "s,/usr,$(TARGET_DEST_DIR)/usr,g"   liblber.la libldap.la libldap_r.la libslapi.la ; \
+	   sed -i "s,L/lib,L$(TARGET_DEST_DIR)/lib,g" liblber.la libldap.la libldap_r.la libslapi.la ; \
+	 )
+	@( cd $(TARGET_DEST_DIR)/usr/libexec/openldap ; \
+	   sed -i "s,/usr,$(TARGET_DEST_DIR)/usr,g"  accesslog.la  auditlog.la     back_dnssrv.la  back_meta.la  \
+	                                             back_null.la  back_passwd.la  back_relay.la   back_shell.la \
+	                                             back_sock.la  back_sql.la     collect.la      constraint.la \
+	                                             dds.la        deref.la        dyngroup.la     dynlist.la    \
+	                                             memberof.la   pcache.la       ppolicy.la      refint.la     \
+	                                             retcode.la    rwm.la          seqmod.la       sssvlv.la     \
+	                                             syncprov.la   translucent.la  unique.la       valsort.la  ; \
+	   sed -i "s,L/lib,L$(TARGET_DEST_DIR)/lib,g"  accesslog.la  auditlog.la     back_dnssrv.la  back_meta.la  \
+	                                               back_null.la  back_passwd.la  back_relay.la   back_shell.la \
+	                                               back_sock.la  back_sql.la     collect.la      constraint.la \
+	                                               dds.la        deref.la        dyngroup.la     dynlist.la    \
+	                                               memberof.la   pcache.la       ppolicy.la      refint.la     \
+	                                               retcode.la    rwm.la          seqmod.la       sssvlv.la     \
+	                                               syncprov.la   translucent.la  unique.la       valsort.la  ; \
+	 )
+	# ======= Strip binaries =======
+	@( cd $(OPENLDAP_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 ; \
+	 )
+ifeq ($(__ENABLE_STATIC__),yes)
+	@( cd $(OPENLDAP_PKG) ; \
+	   find . | xargs file | grep "current ar archive" | cut -f 1 -d : | xargs $(STRIP) -g 2> /dev/null ; \
+	 )
+endif
+ifneq ($(PATCHELF),)
+	# ======= Set RPATH/RUNPATH for target binaries =======
+	@( cd $(OPENLDAP_PKG)/usr ; \
+	   for file in `find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs echo` ; do \
+	     rpath=`$(PATCHELF) --print-rpath $$file 2> /dev/null` ; \
+	     if echo "$$rpath" | grep -q "$(TARGET_DEST_DIR)" ; then \
+	       $(PATCHELF) --set-rpath $(TARGET_BIN_RPATH) $$file 1> /dev/null 2> /dev/null ; \
+	     fi ; \
+	   done ; \
+	 )
+	# ======= Set RPATH/RUNPATH for target shared objects =======
+	@( cd $(OPENLDAP_PKG)/usr ; \
+	   for file in `find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs echo` ; do \
+	     rpath=`$(PATCHELF) --print-rpath $$file 2> /dev/null` ; \
+	     if echo "$$rpath" | grep -q "$(TARGET_DEST_DIR)" ; then \
+	       $(PATCHELF) --set-rpath $(TARGET_LIB_RPATH) $$file 1> /dev/null 2> /dev/null ; \
+	     fi ; \
+	   done ; \
+	 )
+endif
+	@touch $@
+
+$(OPENLDAP_PKG_DESCRIPTION_FILE): $(OPENLDAP_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) $(OPENLDAP_PKG_DESCRIPTION_FILE) $(OPENLDAP_PKG_INSTALL_SCRIPT)
+	@cp $(OPENLDAP_PKG_DESCRIPTION_FILE) $(OPENLDAP_PKG)/.DESCRIPTION
+	@cp $(OPENLDAP_PKG_INSTALL_SCRIPT) $(OPENLDAP_PKG)/.INSTALL
+	@$(BUILD_PKG_REQUIRES) $(OPENLDAP_PKG)/.REQUIRES
+	@echo "pkgname=$(OPENLDAP_PKG_NAME)"                            >  $(OPENLDAP_PKG)/.PKGINFO ; \
+	 echo "pkgver=$(OPENLDAP_PKG_VERSION)"                          >> $(OPENLDAP_PKG)/.PKGINFO ; \
+	 echo "arch=$(OPENLDAP_PKG_ARCH)"                               >> $(OPENLDAP_PKG)/.PKGINFO ; \
+	 echo "distroname=$(OPENLDAP_PKG_DISTRO_NAME)"                  >> $(OPENLDAP_PKG)/.PKGINFO ; \
+	 echo "distrover=$(OPENLDAP_PKG_DISTRO_VERSION)"                >> $(OPENLDAP_PKG)/.PKGINFO ; \
+	 echo "group=$(OPENLDAP_PKG_GROUP)"                             >> $(OPENLDAP_PKG)/.PKGINFO ; \
+	 echo "short_description=\"$(OPENLDAP_PKG_SHORT_DESCRIPTION)\"" >> $(OPENLDAP_PKG)/.PKGINFO ; \
+	 echo "url=$(OPENLDAP_PKG_URL)"                                 >> $(OPENLDAP_PKG)/.PKGINFO ; \
+	 echo "license=$(OPENLDAP_PKG_LICENSE)"                         >> $(OPENLDAP_PKG)/.PKGINFO
+	@$(PSEUDO) sh -c "cd $(OPENLDAP_PKG) && \
+	                  chown -R root:root .              && \
+	                  chmod 700 var/lib/openldap        && \
+	                  chown -R 330:330 var/lib/openldap && \
+	                  chown -R 330:330 etc/openldap     && \
+	                  $(MAKE_PACKAGE) -J --linkadd=yes $(GNUPG_OPTIONS) -m -d .. ."
Index: 2.4.58/PATCHES
===================================================================
Index: 2.4.58/openldap-pkg-description.in
===================================================================
--- 2.4.58/openldap-pkg-description.in	(nonexistent)
+++ 2.4.58/openldap-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------------------------------------------------------|
+openldap: openldap @VERSION@ (Lightweight Directory Access Protocol)
+openldap:
+openldap: OpenLDAP is an open source implementation of the Lightweight
+openldap: Directory Access Protocol. LDAP is a alternative to the X.500
+openldap: Directory Access Protocol (DAP). It uses the TCP/IP stack versus
+openldap: the overly complex OSI stack.
+openldap:
+openldap: LDAP is often used to provide authentication (such as for email).
+openldap:
+openldap: The OpenLDAP homepage is http://www.openldap.org/
+openldap:
Index: 2.4.58/openldap-pkg-install.sh
===================================================================
--- 2.4.58/openldap-pkg-install.sh	(nonexistent)
+++ 2.4.58/openldap-pkg-install.sh	(revision 5)
@@ -0,0 +1,78 @@
+#!/bin/sh
+
+# Preserve new files
+install_file() {
+  NEW="$1"
+  OLD="`dirname $NEW`/`basename $NEW .new`"
+  # If there's no file by that name, mv it over:
+  if [ ! -r $OLD ]; then
+    mv $NEW $OLD
+  elif [ "`cat $OLD | md5sum`" = "`cat $NEW | md5sum`" ]; then # toss the redundant copy
+    rm $NEW
+  fi
+  # Otherwise, we leave the .new copy for the admin to consider...
+}
+
+preserve_perms() {
+  NEW="$1"
+  OLD="$(dirname $NEW)/$(basename $NEW .new)"
+  if [ -e $OLD ]; then
+    cp -a $OLD ${NEW}.incoming
+    cat $NEW > ${NEW}.incoming
+    mv ${NEW}.incoming $NEW
+  fi
+  install_file $NEW
+}
+
+
+# arg 1:  the new package version
+pre_install() {
+  /bin/true
+}
+
+# arg 1:  the new package version
+post_install() {
+  if ! grep -q "^ldap:" etc/passwd ; then
+    echo "ldap:x:330:330:OpenLDAP server:/var/lib/openldap:/bin/false" >> etc/passwd
+  fi
+  if ! grep -q "^ldap:" etc/group ; then
+    echo "ldap:x:330:" >> etc/group
+  fi
+  if ! grep -q "^ldap:" etc/shadow ; then
+    echo "ldap:*:9797:0:::::" >> etc/shadow
+  fi
+
+  preserve_perms etc/rc.d/rc.openldap.new
+  install_file   etc/default/slapd.new
+  install_file   etc/openldap/ldap.conf.new
+  install_file   etc/openldap/slapd.conf.new
+  install_file   etc/openldap/slapd.ldif.new
+}
+
+# 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: 2.4.58/openldap-pkg-install.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: 2.4.58/scripts/rc.openldap
===================================================================
--- 2.4.58/scripts/rc.openldap	(nonexistent)
+++ 2.4.58/scripts/rc.openldap	(revision 5)
@@ -0,0 +1,69 @@
+#!/bin/sh
+# Start/stop/restart the OpenLDAP server (slapd).
+
+# Source default settings:
+if [ -r /etc/default/slapd ]; then
+  . /etc/default/slapd
+fi
+
+# If needed, create run directory:
+if [ ! -d /var/run/openldap ]; then
+  mkdir -p /var/run/openldap
+  chown ldap:ldap /var/run/openldap
+fi
+
+slapd_start() {
+  if [ -e /var/run/openldap/slapd.pid ]; then
+    echo "ERROR: Not starting OpenLDAP server because /var/run/openldap/slapd.pid exists."
+  elif [ -x /usr/sbin/slapd ]; then
+    echo "Starting OpenLDAP server:  /usr/sbin/slapd -u ldap -h "$SLAPD_URLS" $SLAPD_OPTIONS"
+    /usr/sbin/slapd -u ldap -h "$SLAPD_URLS" $SLAPD_OPTIONS 1> /dev/null 2> /dev/null
+  fi
+}
+
+slapd_stop() {
+  if [ -e /var/run/openldap/slapd.pid ]; then
+    echo "Stopping OpenLDAP server."
+    kill -INT $(cat /var/run/openldap/slapd.pid)
+  else
+    echo "ERROR: Not stopping OpenLDAP server because /var/run/openldap/slapd.pid does not exist."
+  fi
+  rm -f /var/run/openldap/slapd.pid
+}
+
+slapd_restart() {
+  slapd_stop
+  sleep 1
+  slapd_start
+}
+
+slapd_status() {
+  if [ -e /var/run/openldap/slapd.pid ]; then
+    if ps axc | grep slapd >/dev/null 2>&1; then
+      echo "OpenLDAP is running."
+      return 0
+    fi
+    echo "OpenLDAP PID file exists but the service is down."
+    return 1
+  else
+    echo "OpenLDAP is stopped."
+    return 0
+  fi
+}
+
+case "$1" in
+  'start')
+    slapd_start
+    ;;
+  'stop')
+    slapd_stop
+    ;;
+  'restart')
+    slapd_restart
+    ;;
+  'status')
+    slapd_status
+    ;;
+  *)
+    echo "usage $0 start|stop|restart"
+esac
Index: 2.4.58/scripts/slapd
===================================================================
--- 2.4.58/scripts/slapd	(nonexistent)
+++ 2.4.58/scripts/slapd	(revision 5)
@@ -0,0 +1,16 @@
+# OpenLDAP server configuration
+# see 'man slapd' for additional information
+
+# Where the server will run (-h option)
+# - ldapi:/// is required for on-the-fly configuration using client tools
+#   (use SASL with EXTERNAL mechanism for authentication)
+# - default: ldapi:/// ldap:///
+# - example: ldapi:/// ldap://127.0.0.1/ ldap://10.0.0.1:1389/ ldaps:///
+SLAPD_URLS="ldapi:/// ldap:///"
+
+# Any custom options
+#SLAPD_OPTIONS=""
+
+# Keytab location for GSSAPI Kerberos authentication
+#KRB5_KTNAME="FILE:/etc/openldap/ldap.keytab"
+
Index: 2.4.58/scripts
===================================================================
--- 2.4.58/scripts	(nonexistent)
+++ 2.4.58/scripts	(revision 5)

Property changes on: 2.4.58/scripts
___________________________________________________________________
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
+*~
Index: 2.4.58
===================================================================
--- 2.4.58	(nonexistent)
+++ 2.4.58	(revision 5)

Property changes on: 2.4.58
___________________________________________________________________
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
+*~
Index: 2.4.58-ppc32/Makefile
===================================================================
--- 2.4.58-ppc32/Makefile	(nonexistent)
+++ 2.4.58-ppc32/Makefile	(revision 5)
@@ -0,0 +1,219 @@
+
+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/n/openldap
+
+REQUIRES           = net/openldap/2.4.58
+REQUIRES          += net/openssl/1.1.1r-ppc32
+REQUIRES          += env/cyrus-sasl/2.1.27-ppc32
+
+# ======= __END_OF_REQUIRES__ =======
+
+
+version            = 2.4.58
+tar_gz_archive     = $(SRC_PACKAGE_PATH)/packages/n/openldap/openldap-$(version).tgz
+SRC_ARCHIVE        = $(tar_gz_archive)
+SRC_DIR            = $(TARGET_BUILD_DIR)/openldap-$(version)
+src_dir_name       = openldap-$(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 = net
+#
+# *PKG_NAME & *PKG_VERSION shouldn't be a reference to value.
+#
+OPENLDAP_32_PKG_NAME                = openldap-x32
+OPENLDAP_32_PKG_VERSION             = 2.4.58
+OPENLDAP_32_PKG_ARCH                = $(PKGARCH)
+OPENLDAP_32_PKG_DISTRO_NAME         = $(DISTRO_NAME)
+OPENLDAP_32_PKG_DISTRO_VERSION      = $(DISTRO_VERSION)
+OPENLDAP_32_PKG_GROUP               = $(PKG_GROUP)
+###                                  |---handy-ruler-------------------------------|
+OPENLDAP_32_PKG_SHORT_DESCRIPTION   = Lightweight Directory Access Protocol
+OPENLDAP_32_PKG_URL                 = $(BUG_URL)
+OPENLDAP_32_PKG_LICENSE             = custom
+OPENLDAP_32_PKG_DESCRIPTION_FILE    = $(TARGET_BUILD_DIR)/$(OPENLDAP_32_PKG_NAME)-pkg-description
+OPENLDAP_32_PKG_DESCRIPTION_FILE_IN = $(OPENLDAP_32_PKG_NAME)-pkg-description.in
+OPENLDAP_32_PKG_INSTALL_SCRIPT      = $(OPENLDAP_32_PKG_NAME)-pkg-install.sh
+
+OPENLDAP_32_PKG  = $(CURDIR)/$(TARGET_BUILD_DIR)/$(OPENLDAP_32_PKG_NAME)-package
+
+pkg_basename     = $(OPENLDAP_32_PKG_NAME)-$(OPENLDAP_32_PKG_VERSION)-$(OPENLDAP_32_PKG_ARCH)-$(OPENLDAP_32_PKG_DISTRO_NAME)-$(OPENLDAP_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=$(OPENLDAP_32_PKG)
+
+
+extra_configure_switches  = --libdir=/usr/lib$(MULTILIB_PPC32_SUFFIX)
+extra_configure_switches += --docdir=/usr/share/doc/$(src_dir_name)
+extra_configure_switches += --infodir=/usr/share/info
+extra_configure_switches += --mandir=/usr/share/man
+extra_configure_switches += --sysconfdir=/etc
+extra_configure_switches += --localstatedir=/var
+
+extra_configure_switches += --bindir=/usr/bin/32
+
+extra_configure_switches += --enable-debug
+extra_configure_switches += --enable-dynamic
+extra_configure_switches += --enable-syslog
+extra_configure_switches += --enable-proctitle
+extra_configure_switches += --enable-ipv6
+extra_configure_switches += --enable-local
+
+extra_configure_switches += --disable-slapd
+
+extra_configure_switches += --with-cyrus-sasl
+extra_configure_switches += --without-fetch
+extra_configure_switches += --with-threads
+extra_configure_switches += --with-pic
+extra_configure_switches += --with-tls
+
+extra_configure_switches += --with-yielding-select=yes
+
+ifeq ($(__ENABLE_STATIC__),yes)
+extra_configure_switches += --enable-static=yes
+else
+extra_configure_switches += --enable-static=no
+endif
+extra_configure_switches += --enable-shared=yes
+
+
+LDFLAGS += -Wl,-rpath=/lib$(MULTILIB_PPC32_SUFFIX):/usr/lib$(MULTILIB_PPC32_SUFFIX):/usr/lib/../lib$(MULTILIB_PPC32_SUFFIX)
+
+
+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)
+
+
+####### Dependencies
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+	$(UNPACK_SRC_ARCHIVE)
+	$(APPLY_PATCHES)
+	@touch $@
+
+$(build_target): $(src_done)
+	@mkdir -p $(build_dir)
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) ../$(src_dir_name)/configure \
+	  --prefix=/usr               \
+	  --build=$(BUILD)            \
+	  --host=$(TARGET32)          \
+	  $(extra_configure_switches)
+	@( cd $(build_dir) ; \
+	   sed -i "s,#define NEED_MEMCMP_REPLACEMENT 1,/* #undef NEED_MEMCMP_REPLACEMENT */," include/portable.h ; \
+	   find . -type f -name Makefile -exec \
+	     sed -i 's,STRIP = -s,STRIP =,g' {} \; ; \
+	 )
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) $(MAKE)
+	@touch $@
+
+$(install_target): $(build_target)
+	@mkdir -p $(OPENLDAP_32_PKG)
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) $(MAKE) -j1 install $(env_sysroot)
+	@chmod 0755 $(OPENLDAP_32_PKG)/usr/lib$(MULTILIB_PPC32_SUFFIX)/lib*.la
+	@chmod 0755 $(OPENLDAP_32_PKG)/usr/lib$(MULTILIB_PPC32_SUFFIX)/lib*.so.?.*
+	@rm -rf $(OPENLDAP_32_PKG)/etc
+	@rm -rf $(OPENLDAP_32_PKG)/usr/include
+	@rm -rf $(OPENLDAP_32_PKG)/usr/share
+	# ======= remove toolchain path from target libtool *.la files =======
+	@( cd $(OPENLDAP_32_PKG)/usr/lib$(MULTILIB_PPC32_SUFFIX) ; \
+	   sed -i "s,$(TARGET_DEST_DIR),,g" liblber.la libldap.la libldap_r.la ; \
+	 )
+	# ======= Install the same to $(TARGET_DEST_DIR) =======
+	$(call install-into-devenv, $(OPENLDAP_32_PKG))
+	# ======= tune libtool *.la search path to the target destination for development =======
+	@( cd $(TARGET_DEST_DIR)/usr/lib$(MULTILIB_PPC32_SUFFIX) ; \
+	  sed -i "s,/usr,$(TARGET_DEST_DIR)/usr,g"   liblber.la libldap.la libldap_r.la ; \
+	  sed -i "s,L/lib,L$(TARGET_DEST_DIR)/lib,g" liblber.la libldap.la libldap_r.la ; \
+	 )
+	# ======= Strip binaries =======
+	@( cd $(OPENLDAP_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 ; \
+	 )
+ifeq ($(__ENABLE_STATIC__),yes)
+	@( cd $(OPENLDAP_32_PKG) ; \
+	   find . | xargs file | grep "current ar archive" | cut -f 1 -d : | xargs $(STRIP) -g 2> /dev/null ; \
+	 )
+endif
+ifneq ($(PATCHELF),)
+	# ======= Set RPATH/RUNPATH for target binaries =======
+	@( cd $(OPENLDAP_32_PKG)/usr/bin/32 ; \
+	   for file in `find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs echo` ; do \
+	     rpath=`$(PATCHELF) --print-rpath $$file 2> /dev/null` ; \
+	     if echo "$$rpath" | grep -q "$(TARGET_DEST_DIR)" ; then \
+	       $(PATCHELF) --set-rpath $(TARGET_BIN_RPATH) $$file 1> /dev/null 2> /dev/null ; \
+	     fi ; \
+	   done ; \
+	 )
+	# ======= Set RPATH/RUNPATH for target shared objects =======
+	@( cd $(OPENLDAP_32_PKG)/usr/lib$(MULTILIB_PPC32_SUFFIX) ; \
+	   for file in `find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs echo` ; do \
+	     rpath=`$(PATCHELF) --print-rpath $$file 2> /dev/null` ; \
+	     if echo "$$rpath" | grep -q "$(TARGET_DEST_DIR)" ; then \
+	       $(PATCHELF) --set-rpath $(TARGET_LIB_RPATH) $$file 1> /dev/null 2> /dev/null ; \
+	     fi ; \
+	   done ; \
+	 )
+endif
+	@touch $@
+
+$(OPENLDAP_32_PKG_DESCRIPTION_FILE): $(OPENLDAP_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) $(OPENLDAP_32_PKG_DESCRIPTION_FILE) $(OPENLDAP_32_PKG_INSTALL_SCRIPT)
+	@cp $(OPENLDAP_32_PKG_DESCRIPTION_FILE) $(OPENLDAP_32_PKG)/.DESCRIPTION
+	@cp $(OPENLDAP_32_PKG_INSTALL_SCRIPT) $(OPENLDAP_32_PKG)/.INSTALL
+	@$(BUILD_PKG_REQUIRES) $(OPENLDAP_32_PKG)/.REQUIRES
+	@echo "pkgname=$(OPENLDAP_32_PKG_NAME)"                            >  $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "pkgver=$(OPENLDAP_32_PKG_VERSION)"                          >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "arch=$(OPENLDAP_32_PKG_ARCH)"                               >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "distroname=$(OPENLDAP_32_PKG_DISTRO_NAME)"                  >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "distrover=$(OPENLDAP_32_PKG_DISTRO_VERSION)"                >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "group=$(OPENLDAP_32_PKG_GROUP)"                             >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "short_description=\"$(OPENLDAP_32_PKG_SHORT_DESCRIPTION)\"" >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "url=$(OPENLDAP_32_PKG_URL)"                                 >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "license=$(OPENLDAP_32_PKG_LICENSE)"                         >> $(OPENLDAP_32_PKG)/.PKGINFO
+	@$(PSEUDO) sh -c "cd $(OPENLDAP_32_PKG) && \
+	                  chown -R root:root .  && \
+	                  $(MAKE_PACKAGE) -J --linkadd=yes $(GNUPG_OPTIONS) -m -d .. ."
Index: 2.4.58-ppc32/PATCHES
===================================================================
Index: 2.4.58-ppc32/openldap-x32-pkg-description.in
===================================================================
--- 2.4.58-ppc32/openldap-x32-pkg-description.in	(nonexistent)
+++ 2.4.58-ppc32/openldap-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------------------------------------------------------|
+openldap-x32: openldap-x32 @VERSION@ (Lightweight Directory Access Protocol)
+openldap-x32:
+openldap-x32: OpenLDAP is an open source implementation of the Lightweight
+openldap-x32: Directory Access Protocol. LDAP is a alternative to the X.500
+openldap-x32: Directory Access Protocol (DAP). It uses the TCP/IP stack versus
+openldap-x32: the overly complex OSI stack.
+openldap-x32:
+openldap-x32: LDAP is often used to provide authentication (such as for email).
+openldap-x32:
+openldap-x32: The OpenLDAP homepage is http://www.openldap.org/
+openldap-x32:
Index: 2.4.58-ppc32/openldap-x32-pkg-install.sh
===================================================================
--- 2.4.58-ppc32/openldap-x32-pkg-install.sh	(nonexistent)
+++ 2.4.58-ppc32/openldap-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: 2.4.58-ppc32/openldap-x32-pkg-install.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: 2.4.58-ppc32
===================================================================
--- 2.4.58-ppc32	(nonexistent)
+++ 2.4.58-ppc32	(revision 5)

Property changes on: 2.4.58-ppc32
___________________________________________________________________
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
+*~
Index: 2.4.58-x86_32/Makefile
===================================================================
--- 2.4.58-x86_32/Makefile	(nonexistent)
+++ 2.4.58-x86_32/Makefile	(revision 5)
@@ -0,0 +1,216 @@
+
+COMPONENT_TARGETS  = $(HARDWARE_INTEL_PC64)
+
+NEED_ABS_PATH      = true
+COMPONENT_IS_3PP   = true
+
+CREATE_X86_32_PACKAGE = true
+
+
+include ../../../build-system/constants.mk
+
+
+SOURCE_REQUIRES    = sources/packages/n/openldap
+
+REQUIRES           = net/openldap/2.4.58
+REQUIRES          += net/openssl/1.1.1r-x86_32
+REQUIRES          += env/cyrus-sasl/2.1.27-x86_32
+
+# ======= __END_OF_REQUIRES__ =======
+
+
+version            = 2.4.58
+tar_gz_archive     = $(SRC_PACKAGE_PATH)/packages/n/openldap/openldap-$(version).tgz
+SRC_ARCHIVE        = $(tar_gz_archive)
+SRC_DIR            = $(TARGET_BUILD_DIR)/openldap-$(version)
+src_dir_name       = openldap-$(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 = net
+#
+# *PKG_NAME & *PKG_VERSION shouldn't be a reference to value.
+#
+OPENLDAP_32_PKG_NAME                = openldap-x32
+OPENLDAP_32_PKG_VERSION             = 2.4.58
+OPENLDAP_32_PKG_ARCH                = $(PKGARCH)
+OPENLDAP_32_PKG_DISTRO_NAME         = $(DISTRO_NAME)
+OPENLDAP_32_PKG_DISTRO_VERSION      = $(DISTRO_VERSION)
+OPENLDAP_32_PKG_GROUP               = $(PKG_GROUP)
+###                                  |---handy-ruler-------------------------------|
+OPENLDAP_32_PKG_SHORT_DESCRIPTION   = Lightweight Directory Access Protocol
+OPENLDAP_32_PKG_URL                 = $(BUG_URL)
+OPENLDAP_32_PKG_LICENSE             = custom
+OPENLDAP_32_PKG_DESCRIPTION_FILE    = $(TARGET_BUILD_DIR)/$(OPENLDAP_32_PKG_NAME)-pkg-description
+OPENLDAP_32_PKG_DESCRIPTION_FILE_IN = $(OPENLDAP_32_PKG_NAME)-pkg-description.in
+OPENLDAP_32_PKG_INSTALL_SCRIPT      = $(OPENLDAP_32_PKG_NAME)-pkg-install.sh
+
+OPENLDAP_32_PKG  = $(CURDIR)/$(TARGET_BUILD_DIR)/$(OPENLDAP_32_PKG_NAME)-package
+
+pkg_basename     = $(OPENLDAP_32_PKG_NAME)-$(OPENLDAP_32_PKG_VERSION)-$(OPENLDAP_32_PKG_ARCH)-$(OPENLDAP_32_PKG_DISTRO_NAME)-$(OPENLDAP_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=$(OPENLDAP_32_PKG)
+
+
+extra_configure_switches  = --libdir=/usr/lib$(MULTILIB_X86_32_SUFFIX)
+extra_configure_switches += --docdir=/usr/share/doc/$(src_dir_name)
+extra_configure_switches += --infodir=/usr/share/info
+extra_configure_switches += --mandir=/usr/share/man
+extra_configure_switches += --sysconfdir=/etc
+extra_configure_switches += --localstatedir=/var
+
+extra_configure_switches += --bindir=/usr/bin/32
+
+extra_configure_switches += --enable-debug
+extra_configure_switches += --enable-dynamic
+extra_configure_switches += --enable-syslog
+extra_configure_switches += --enable-proctitle
+extra_configure_switches += --enable-ipv6
+extra_configure_switches += --enable-local
+
+extra_configure_switches += --disable-slapd
+
+extra_configure_switches += --with-cyrus-sasl
+extra_configure_switches += --without-fetch
+extra_configure_switches += --with-threads
+extra_configure_switches += --with-pic
+extra_configure_switches += --with-tls
+
+extra_configure_switches += --with-yielding-select=yes
+
+ifeq ($(__ENABLE_STATIC__),yes)
+extra_configure_switches += --enable-static=yes
+else
+extra_configure_switches += --enable-static=no
+endif
+extra_configure_switches += --enable-shared=yes
+
+
+LDFLAGS += -Wl,-rpath=/lib$(MULTILIB_X86_32_SUFFIX):/usr/lib$(MULTILIB_X86_32_SUFFIX):/usr/lib/../lib$(MULTILIB_X86_32_SUFFIX)
+
+
+TARGET_BIN_RPATH = /lib$(MULTILIB_X86_32_SUFFIX):/usr/lib$(MULTILIB_X86_32_SUFFIX)
+TARGET_LIB_RPATH = /lib$(MULTILIB_X86_32_SUFFIX):/usr/lib$(MULTILIB_X86_32_SUFFIX):/usr/lib/../lib$(MULTILIB_X86_32_SUFFIX)
+
+
+####### Dependencies
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+	$(UNPACK_SRC_ARCHIVE)
+	$(APPLY_PATCHES)
+	@touch $@
+
+$(build_target): $(src_done)
+	@mkdir -p $(build_dir)
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) ../$(src_dir_name)/configure \
+	  --prefix=/usr               \
+	  --build=$(BUILD)            \
+	  --host=$(TARGET32)          \
+	  $(extra_configure_switches)
+	@( cd $(build_dir) ; \
+	   sed -i "s,#define NEED_MEMCMP_REPLACEMENT 1,/* #undef NEED_MEMCMP_REPLACEMENT */," include/portable.h ; \
+	   find . -type f -name Makefile -exec \
+	     sed -i 's,STRIP = -s,STRIP =,g' {} \; ; \
+	 )
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) $(MAKE)
+	@touch $@
+
+$(install_target): $(build_target)
+	@mkdir -p $(OPENLDAP_32_PKG)
+	@cd $(build_dir) && $(BUILD_ENVIRONMENT) $(MAKE) -j1 install $(env_sysroot)
+	@chmod 0755 $(OPENLDAP_32_PKG)/usr/lib$(MULTILIB_X86_32_SUFFIX)/lib*.la
+	@chmod 0755 $(OPENLDAP_32_PKG)/usr/lib$(MULTILIB_X86_32_SUFFIX)/lib*.so.?.*
+	@rm -rf $(OPENLDAP_32_PKG)/etc
+	@rm -rf $(OPENLDAP_32_PKG)/usr/include
+	@rm -rf $(OPENLDAP_32_PKG)/usr/share
+	# ======= remove toolchain path from target libtool *.la files =======
+	@( cd $(OPENLDAP_32_PKG)/usr/lib$(MULTILIB_X86_32_SUFFIX) ; \
+	   sed -i "s,$(TARGET_DEST_DIR),,g" liblber.la libldap.la libldap_r.la ; \
+	 )
+	# ======= Install the same to $(TARGET_DEST_DIR) =======
+	$(call install-into-devenv, $(OPENLDAP_32_PKG))
+	# ======= tune libtool *.la search path to the target destination for development =======
+	@( cd $(TARGET_DEST_DIR)/usr/lib$(MULTILIB_X86_32_SUFFIX) ; \
+	  sed -i "s,/usr,$(TARGET_DEST_DIR)/usr,g"   liblber.la libldap.la libldap_r.la ; \
+	  sed -i "s,L/lib,L$(TARGET_DEST_DIR)/lib,g" liblber.la libldap.la libldap_r.la ; \
+	 )
+	# ======= Strip binaries =======
+	@( cd $(OPENLDAP_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 ; \
+	 )
+ifeq ($(__ENABLE_STATIC__),yes)
+	@( cd $(OPENLDAP_32_PKG) ; \
+	   find . | xargs file | grep "current ar archive" | cut -f 1 -d : | xargs $(STRIP) -g 2> /dev/null ; \
+	 )
+endif
+ifneq ($(PATCHELF),)
+	# ======= Set RPATH/RUNPATH for target binaries =======
+	@( cd $(OPENLDAP_32_PKG)/usr/bin/32 ; \
+	   for file in `find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs echo` ; do \
+	     rpath=`$(PATCHELF) --print-rpath $$file 2> /dev/null` ; \
+	     if echo "$$rpath" | grep -q "$(TARGET_DEST_DIR)" ; then \
+	       $(PATCHELF) --set-rpath $(TARGET_BIN_RPATH) $$file 1> /dev/null 2> /dev/null ; \
+	     fi ; \
+	   done ; \
+	 )
+	# ======= Set RPATH/RUNPATH for target shared objects =======
+	@( cd $(OPENLDAP_32_PKG)/usr/lib$(MULTILIB_X86_32_SUFFIX) ; \
+	   for file in `find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs echo` ; do \
+	     rpath=`$(PATCHELF) --print-rpath $$file 2> /dev/null` ; \
+	     if echo "$$rpath" | grep -q "$(TARGET_DEST_DIR)" ; then \
+	       $(PATCHELF) --set-rpath $(TARGET_LIB_RPATH) $$file 1> /dev/null 2> /dev/null ; \
+	     fi ; \
+	   done ; \
+	 )
+endif
+	@touch $@
+
+$(OPENLDAP_32_PKG_DESCRIPTION_FILE): $(OPENLDAP_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) $(OPENLDAP_32_PKG_DESCRIPTION_FILE) $(OPENLDAP_32_PKG_INSTALL_SCRIPT)
+	@cp $(OPENLDAP_32_PKG_DESCRIPTION_FILE) $(OPENLDAP_32_PKG)/.DESCRIPTION
+	@cp $(OPENLDAP_32_PKG_INSTALL_SCRIPT) $(OPENLDAP_32_PKG)/.INSTALL
+	@$(BUILD_PKG_REQUIRES) $(OPENLDAP_32_PKG)/.REQUIRES
+	@echo "pkgname=$(OPENLDAP_32_PKG_NAME)"                            >  $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "pkgver=$(OPENLDAP_32_PKG_VERSION)"                          >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "arch=$(OPENLDAP_32_PKG_ARCH)"                               >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "distroname=$(OPENLDAP_32_PKG_DISTRO_NAME)"                  >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "distrover=$(OPENLDAP_32_PKG_DISTRO_VERSION)"                >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "group=$(OPENLDAP_32_PKG_GROUP)"                             >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "short_description=\"$(OPENLDAP_32_PKG_SHORT_DESCRIPTION)\"" >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "url=$(OPENLDAP_32_PKG_URL)"                                 >> $(OPENLDAP_32_PKG)/.PKGINFO ; \
+	 echo "license=$(OPENLDAP_32_PKG_LICENSE)"                         >> $(OPENLDAP_32_PKG)/.PKGINFO
+	@$(PSEUDO) sh -c "cd $(OPENLDAP_32_PKG) && \
+	                  chown -R root:root .  && \
+	                  $(MAKE_PACKAGE) -J --linkadd=yes $(GNUPG_OPTIONS) -m -d .. ."
Index: 2.4.58-x86_32/PATCHES
===================================================================
Index: 2.4.58-x86_32/openldap-x32-pkg-description.in
===================================================================
--- 2.4.58-x86_32/openldap-x32-pkg-description.in	(nonexistent)
+++ 2.4.58-x86_32/openldap-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------------------------------------------------------|
+openldap-x32: openldap-x32 @VERSION@ (Lightweight Directory Access Protocol)
+openldap-x32:
+openldap-x32: OpenLDAP is an open source implementation of the Lightweight
+openldap-x32: Directory Access Protocol. LDAP is a alternative to the X.500
+openldap-x32: Directory Access Protocol (DAP). It uses the TCP/IP stack versus
+openldap-x32: the overly complex OSI stack.
+openldap-x32:
+openldap-x32: LDAP is often used to provide authentication (such as for email).
+openldap-x32:
+openldap-x32: The OpenLDAP homepage is http://www.openldap.org/
+openldap-x32:
Index: 2.4.58-x86_32/openldap-x32-pkg-install.sh
===================================================================
--- 2.4.58-x86_32/openldap-x32-pkg-install.sh	(nonexistent)
+++ 2.4.58-x86_32/openldap-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: 2.4.58-x86_32/openldap-x32-pkg-install.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: 2.4.58-x86_32
===================================================================
--- 2.4.58-x86_32	(nonexistent)
+++ 2.4.58-x86_32	(revision 5)

Property changes on: 2.4.58-x86_32
___________________________________________________________________
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
+*~
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
+*~