initial buildroot for linux 5.15
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
config BR2_PACKAGE_I2PD
|
||||
bool "i2pd"
|
||||
depends on BR2_USE_MMU # fork()
|
||||
depends on BR2_TOOLCHAIN_HAS_ATOMIC
|
||||
# pthread_condattr_setclock
|
||||
depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
|
||||
depends on BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS # boost-filesystem
|
||||
depends on BR2_INSTALL_LIBSTDCPP
|
||||
depends on BR2_USE_WCHAR # boost
|
||||
depends on !BR2_TOOLCHAIN_HAS_GCC_BUG_64735 # exception_ptr
|
||||
select BR2_PACKAGE_BOOST
|
||||
select BR2_PACKAGE_BOOST_DATE_TIME
|
||||
select BR2_PACKAGE_BOOST_FILESYSTEM
|
||||
select BR2_PACKAGE_BOOST_PROGRAM_OPTIONS
|
||||
select BR2_PACKAGE_BOOST_SYSTEM
|
||||
select BR2_PACKAGE_OPENSSL
|
||||
select BR2_PACKAGE_ZLIB
|
||||
help
|
||||
i2pd (I2P Daemon) is a full-featured C++ implementation of I2P
|
||||
client.
|
||||
|
||||
I2P (Invisible Internet Protocol) is a universal anonymous
|
||||
network layer.
|
||||
All communications over I2P are anonymous and end-to-end
|
||||
encrypted, participants don't reveal their real IP addresses.
|
||||
|
||||
http://i2pd.website
|
||||
|
||||
comment "i2pd needs a toolchain w/ C++, NPTL, wchar"
|
||||
depends on BR2_USE_MMU
|
||||
depends on BR2_TOOLCHAIN_HAS_ATOMIC
|
||||
depends on BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS
|
||||
depends on !BR2_INSTALL_LIBSTDCPP || \
|
||||
!BR2_TOOLCHAIN_HAS_THREADS_NPTL || !BR2_USE_WCHAR
|
||||
|
||||
comment "i2pd needs exception_ptr"
|
||||
depends on BR2_USE_MMU
|
||||
depends on BR2_TOOLCHAIN_HAS_ATOMIC
|
||||
depends on BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS
|
||||
depends on BR2_TOOLCHAIN_HAS_GCC_BUG_64735
|
||||
@@ -0,0 +1,38 @@
|
||||
#!/bin/sh
|
||||
|
||||
NAME=i2pd
|
||||
PIDFILE=/var/run/$NAME.pid
|
||||
DAEMON=/usr/bin/$NAME
|
||||
DAEMON_ARGS="--conf=/etc/i2pd/i2pd.conf --tunconf=/etc/i2pd/tunnels.conf --pidfile=/var/run/i2pd.pid --logfile=/var/log/i2pd.log --daemon --service"
|
||||
|
||||
start() {
|
||||
printf "Starting $NAME: "
|
||||
start-stop-daemon -S -q -m -b -p $PIDFILE --exec $DAEMON -- $DAEMON_ARGS
|
||||
[ $? = 0 ] && echo "OK" || echo "FAIL"
|
||||
}
|
||||
stop() {
|
||||
printf "Stopping $NAME: "
|
||||
start-stop-daemon -K -q -p $PIDFILE
|
||||
[ $? = 0 ] && echo "OK" || echo "FAIL"
|
||||
}
|
||||
restart() {
|
||||
stop
|
||||
start
|
||||
}
|
||||
|
||||
case "$1" in
|
||||
start)
|
||||
start
|
||||
;;
|
||||
stop)
|
||||
stop
|
||||
;;
|
||||
restart|reload)
|
||||
restart
|
||||
;;
|
||||
*)
|
||||
echo "Usage: $0 {start|stop|restart}"
|
||||
exit 1
|
||||
esac
|
||||
|
||||
exit $?
|
||||
@@ -0,0 +1,4 @@
|
||||
# From https://github.com/PurpleI2P/i2pd/releases/download/2.39.0/SHA512SUMS
|
||||
sha512 6b38e6e2e763e94ffe9d11eb2f9a0e9554560bb4fec95891240adf5bc0a9639f879dac4ff3712a9f8e00895b7bbeabc854887e61fe9f9755c33f96899e20aa76 i2pd-2.39.0.tar.gz
|
||||
# Locally computed:
|
||||
sha256 9c87aff490b272254d716475e3c4973f5f64af1d18f9f6962c1e61e252e1ad9a LICENSE
|
||||
@@ -0,0 +1,61 @@
|
||||
################################################################################
|
||||
#
|
||||
# i2pd
|
||||
#
|
||||
################################################################################
|
||||
|
||||
I2PD_VERSION = 2.39.0
|
||||
I2PD_SITE = $(call github,PurpleI2P,i2pd,$(I2PD_VERSION))
|
||||
I2PD_LICENSE = BSD-3-Clause
|
||||
I2PD_LICENSE_FILES = LICENSE
|
||||
I2PD_SUBDIR = build
|
||||
I2PD_DEPENDENCIES = \
|
||||
boost \
|
||||
openssl \
|
||||
zlib
|
||||
|
||||
I2PD_CONF_OPTS += -DWITH_GUI=OFF
|
||||
|
||||
ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
|
||||
I2PD_CONF_OPTS += \
|
||||
-DHAVE_CXX_ATOMICS_WITHOUT_LIB=OFF \
|
||||
-DHAVE_CXX_ATOMICS64_WITHOUT_LIB=OFF
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_STATIC_LIBS),y)
|
||||
I2PD_CONF_OPTS += -DWITH_STATIC=ON
|
||||
else
|
||||
I2PD_CONF_OPTS += -DWITH_STATIC=OFF
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_LIBMINIUPNPC),y)
|
||||
I2PD_DEPENDENCIES += libminiupnpc
|
||||
I2PD_CONF_OPTS += -DWITH_UPNP=ON
|
||||
else
|
||||
I2PD_CONF_OPTS += -DWITH_UPNP=OFF
|
||||
endif
|
||||
|
||||
define I2PD_INSTALL_CONFIGURATION_FILES
|
||||
$(INSTALL) -D -m 644 $(@D)/contrib/i2pd.conf \
|
||||
$(TARGET_DIR)/etc/i2pd/i2pd.conf
|
||||
$(INSTALL) -D -m 644 $(@D)/contrib/tunnels.conf \
|
||||
$(TARGET_DIR)/etc/i2pd/tunnels.conf
|
||||
mkdir -p $(TARGET_DIR)/var/lib/i2pd
|
||||
cp -a $(@D)/contrib/certificates $(TARGET_DIR)/var/lib/i2pd
|
||||
endef
|
||||
|
||||
define I2PD_USERS
|
||||
i2pd -1 i2pd -1 * /var/lib/i2pd - - I2P Daemon
|
||||
endef
|
||||
|
||||
define I2PD_INSTALL_INIT_SYSV
|
||||
$(INSTALL) -D -m 0755 package/i2pd/S99i2pd \
|
||||
$(TARGET_DIR)/etc/init.d/S99i2pd
|
||||
endef
|
||||
|
||||
define I2PD_INSTALL_INIT_SYSTEMD
|
||||
$(INSTALL) -D -m 644 package/i2pd/i2pd.service \
|
||||
$(TARGET_DIR)/usr/lib/systemd/system/i2pd.service
|
||||
endef
|
||||
|
||||
$(eval $(cmake-package))
|
||||
@@ -0,0 +1,29 @@
|
||||
[Unit]
|
||||
Description=I2P Router written in C++
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
User=i2pd
|
||||
Group=i2pd
|
||||
RuntimeDirectory=i2pd
|
||||
RuntimeDirectoryMode=0700
|
||||
LogsDirectory=i2pd
|
||||
LogsDirectoryMode=0700
|
||||
Type=simple
|
||||
ExecStart=/usr/bin/i2pd --conf=/etc/i2pd/i2pd.conf --tunconf=/etc/i2pd/tunnels.conf --pidfile=/run/i2pd/i2pd.pid --logfile=/var/log/i2pd/i2pd.log --daemon --service
|
||||
ExecReload=/bin/kill -HUP $MAINPID
|
||||
PIDFile=/run/i2pd/i2pd.pid
|
||||
### Uncomment, if auto restart needed
|
||||
#Restart=on-failure
|
||||
|
||||
### Use SIGINT for graceful stop daemon.
|
||||
# i2pd stops accepting new tunnels and waits ~10 min while old ones do not die.
|
||||
KillSignal=SIGINT
|
||||
TimeoutStopSec=10m
|
||||
|
||||
# If you have problems with hanging i2pd, you can try enable this
|
||||
#LimitNOFILE=4096
|
||||
PrivateDevices=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Reference in New Issue
Block a user