Initial Commit
- initial default booting image
This commit is contained in:
40
package/leafnode2/0001-cross_makefile.patch
Normal file
40
package/leafnode2/0001-cross_makefile.patch
Normal file
@@ -0,0 +1,40 @@
|
||||
Fix cross-compilation issues
|
||||
|
||||
- During target package compilation the host version of b_sortnl is
|
||||
needed.
|
||||
|
||||
- Do not call a 'amiroot' program built for the target when
|
||||
cross-compiling. We're anyway not root, so simply remove the
|
||||
chown/chgrp dance.
|
||||
|
||||
[Bernd: rebased for 2.0.0.alpha202601]
|
||||
Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
|
||||
Index: b/Makefile.am
|
||||
===================================================================
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -324,7 +324,7 @@
|
||||
|
||||
configparam_data.c: $(srcdir)/config.table b_sortnl$(EXEEXT) genconfigparam_data.awk
|
||||
rm -f config.table.sorted
|
||||
- ./b_sortnl$(EXEEXT) <$(srcdir)/config.table >config.table.sorted
|
||||
+ ./b_sortnl_host$(EXEEXT) <$(srcdir)/config.table >config.table.sorted
|
||||
$(AWK) -f $(srcdir)/genconfigparam_data.awk <config.table.sorted >$@ \
|
||||
|| { rm -f $@ ; false ; }
|
||||
|
||||
@@ -339,13 +339,7 @@
|
||||
install-data-hook:
|
||||
$(INSTALL) -d -m 02770 $(DESTDIR)$(SPOOLDIR)
|
||||
$(INSTALL) -d -m 02770 $(DESTDIR)$(SPOOLDIR)/leaf.node
|
||||
- -./amiroot && chown $(RUNAS_USER) $(DESTDIR)$(SPOOLDIR)
|
||||
- -./amiroot && chown $(RUNAS_USER) $(DESTDIR)$(SPOOLDIR)/leaf.node
|
||||
- -./amiroot && chgrp $(RUNAS_GROUP) $(DESTDIR)$(SPOOLDIR)
|
||||
- -./amiroot && chgrp $(RUNAS_GROUP) $(DESTDIR)$(SPOOLDIR)/leaf.node
|
||||
rm -f $(DESTDIR)$(sbindir)/leafnode-version # now in $(bindir)
|
||||
- ./amiroot && p=$(DESTDIR)$(bindir)/newsq && chown 0 $$p \
|
||||
- && chgrp $(RUNAS_GROUP) $$p && chmod 2111 $$p ; true
|
||||
@echo
|
||||
@echo "### If upgrading from leafnode before 1.6,"
|
||||
@echo "### run: make update"
|
||||
11
package/leafnode2/Config.in
Normal file
11
package/leafnode2/Config.in
Normal file
@@ -0,0 +1,11 @@
|
||||
config BR2_PACKAGE_LEAFNODE2
|
||||
bool "leafnode2"
|
||||
depends on BR2_USE_MMU # fork()
|
||||
select BR2_PACKAGE_LIBXCRYPT if BR2_TOOLCHAIN_USES_GLIBC
|
||||
select BR2_PACKAGE_PCRE2
|
||||
help
|
||||
Leafnode-2 is a store-and-forward NNTP (or Usenet) proxy
|
||||
server designed for small sites with just a few active
|
||||
newsgroups.
|
||||
|
||||
https://gitlab.com/leafnode-2/leafnode-2
|
||||
4
package/leafnode2/leafnode2.hash
Normal file
4
package/leafnode2/leafnode2.hash
Normal file
@@ -0,0 +1,4 @@
|
||||
# Locally calculated
|
||||
sha256 c98201dffc51addf4157ceb67f2ef7f2c0f3813e49342834f243244a872d90c1 leafnode2-2.0.0.alpha202601.tar.gz
|
||||
sha256 59d37f745dc5a2d63a51dff344f4ad89f72e76f8c7b7d877f20880d838b1bec9 COPYING
|
||||
sha256 dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551 COPYING.LGPL
|
||||
53
package/leafnode2/leafnode2.mk
Normal file
53
package/leafnode2/leafnode2.mk
Normal file
@@ -0,0 +1,53 @@
|
||||
################################################################################
|
||||
#
|
||||
# leafnode2
|
||||
#
|
||||
################################################################################
|
||||
|
||||
LEAFNODE2_VERSION = 2.0.0.alpha202601
|
||||
LEAFNODE2_SITE = $(call gitlab,leafnode-2,leafnode-2,leafnode-$(LEAFNODE2_VERSION))
|
||||
LEAFNODE2_LICENSE = LGPL-2.1
|
||||
LEAFNODE2_LICENSE_FILES = COPYING COPYING.LGPL
|
||||
LEAFNODE2_DEPENDENCIES = host-pcre2 pcre2
|
||||
LEAFNODE2_AUTORECONF = YES
|
||||
|
||||
# pod2man doesn't work when cross compiling
|
||||
define LEAFNODE2_DISABLE_POD2MAN
|
||||
$(SED) 's/GENERATED_MANS=lsmac.1/GENERATED_MANS=/' $(@D)/Makefile.am
|
||||
endef
|
||||
LEAFNODE2_POST_PATCH_HOOKS += LEAFNODE2_DISABLE_POD2MAN
|
||||
|
||||
LEAFNODE2_CONF_ENV = \
|
||||
PCRE2CONFIG="$(STAGING_DIR)/usr/bin/pcre2-config"
|
||||
|
||||
ifeq ($(BR2_PACKAGE_LIBXCRYPT),y)
|
||||
LEAFNODE2_DEPENDENCIES += libxcrypt
|
||||
endif
|
||||
|
||||
# --enable-runas-user use 'news' as default but the configure stop
|
||||
# if news doesn't exist on the build host.
|
||||
# Use 'root' while cross-compiling
|
||||
LEAFNODE2_CONF_OPTS = \
|
||||
--sysconfdir=/etc/leafnode2 \
|
||||
--enable-spooldir=/var/spool/news \
|
||||
--enable-runas-user=root
|
||||
|
||||
# Leafnode2 needs the host version of b_sortnl during
|
||||
# compilation. Instead of creating a separate host package and
|
||||
# installing b_sortnl to $(HOST_DIR) this binary is compiled
|
||||
# on-the-fly, host-pcre2 is needed for this
|
||||
define LEAFNODE2_BUILD_SORTNL_TOOL
|
||||
cd $(@D); \
|
||||
$(HOSTCC) $(HOST_CFLAGS) -o b_sortnl_host \
|
||||
arc4random.c mergesort.c b_sortnl.c critmem_malloc.c \
|
||||
critmem_realloc.c -DHAVE_CONFIG_H -I$(HOST_DIR)/include \
|
||||
-L $(HOST_DIR)/lib -Wl,-rpath,$(HOST_DIR)/lib -lpcre2-8
|
||||
endef
|
||||
|
||||
LEAFNODE2_PRE_BUILD_HOOKS += LEAFNODE2_BUILD_SORTNL_TOOL
|
||||
|
||||
define LEAFNODE2_USERS
|
||||
news -1 news -1 * - - - Leafnode2 daemon
|
||||
endef
|
||||
|
||||
$(eval $(autotools-package))
|
||||
Reference in New Issue
Block a user