mirror of
https://gitlab.redox-os.org/redox-os/redox.git
synced 2026-11-05 04:06:38 +08:00
Compare commits
8 Commits
434ce06791
...
c0d5b23274
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c0d5b23274 | ||
|
|
9007d0a29f | ||
|
|
aa01491b88 | ||
|
|
6c094d1376 | ||
|
|
bebe444ca8 | ||
|
|
617d3c35b5 | ||
|
|
23b3e6f991 | ||
|
|
7643fac87b |
@ -29,6 +29,7 @@ xfce4-full = {}
|
||||
|
||||
acid = {}
|
||||
adwaita-icon-theme = {}
|
||||
arti = "source"
|
||||
atk = {}
|
||||
autoconf = {}
|
||||
automake = {}
|
||||
@ -106,6 +107,7 @@ glutin = {}
|
||||
gnu-binutils = {}
|
||||
gnu-grep = {}
|
||||
gnu-make = {}
|
||||
go = {}
|
||||
goaccess = {}
|
||||
gobject-introspection = {}
|
||||
gitoxide = {}
|
||||
@ -126,6 +128,7 @@ intel-one-mono = {}
|
||||
ion = {}
|
||||
kernel = {}
|
||||
kibi = {}
|
||||
lazygit = {}
|
||||
lci = {}
|
||||
libarchive = {}
|
||||
libatomic = {}
|
||||
|
||||
@ -11,6 +11,7 @@ filesystem_size = 3000
|
||||
[packages]
|
||||
|
||||
# GUI Apps
|
||||
cosmic-monitor = {}
|
||||
cosmic-reader = {}
|
||||
periodictable = {}
|
||||
servo = {}
|
||||
@ -29,13 +30,11 @@ vim = {}
|
||||
wget = {}
|
||||
|
||||
# Emulators
|
||||
|
||||
dosbox = {}
|
||||
mednafen = {}
|
||||
flycast = {}
|
||||
|
||||
# Games
|
||||
|
||||
freedoom = {}
|
||||
neverball = {}
|
||||
prboom = {}
|
||||
@ -44,6 +43,7 @@ sopwith = {}
|
||||
syobonaction = {}
|
||||
|
||||
# Demos
|
||||
gtk3 = {}
|
||||
nushell = {}
|
||||
orbclient = {}
|
||||
pixelcannon = {}
|
||||
@ -57,6 +57,12 @@ softbuffer = {}
|
||||
# MIDI
|
||||
freepats = {}
|
||||
|
||||
[[files]]
|
||||
path = "/usr/lib/init.d/20_glib"
|
||||
data = """
|
||||
glib-compile-schemas /usr/share/glib-2.0/schemas/
|
||||
"""
|
||||
|
||||
[[files]]
|
||||
path = "/home/user/Welcome.txt"
|
||||
data = """
|
||||
|
||||
@ -5,23 +5,25 @@ include = ["demo.toml"]
|
||||
# General settings
|
||||
[general]
|
||||
# Filesystem size in MiB
|
||||
filesystem_size = 8192
|
||||
filesystem_size = 16384
|
||||
|
||||
# Package settings
|
||||
[packages]
|
||||
# apps
|
||||
|
||||
# GUI Apps
|
||||
#boxedwine = {}
|
||||
cosmic-player = {}
|
||||
cosmic-reader = {}
|
||||
cosmic-settings = {}
|
||||
cosmic-store = {}
|
||||
cosmic-term = {}
|
||||
cosmic-text = {}
|
||||
#cosmic-player = {}
|
||||
#cosmic-settings = {}
|
||||
#cosmic-store = {}
|
||||
#qemu = {} # not building
|
||||
schismtracker = {}
|
||||
servo = {}
|
||||
|
||||
# cli
|
||||
# GUI Data
|
||||
jeremy = {}
|
||||
noto-color-emoji = {}
|
||||
ttf-hack = {}
|
||||
|
||||
# Terminal Apps
|
||||
cleye = {}
|
||||
ffmpeg6 = {}
|
||||
lua54 = {}
|
||||
@ -34,26 +36,54 @@ sed = {}
|
||||
shellharden = {}
|
||||
xz = {}
|
||||
|
||||
# demos
|
||||
# Emulators
|
||||
mgba = {}
|
||||
#retroarch = {} # need to package cores
|
||||
rs-nes = {} # need game for testing
|
||||
rust64 = {} # need roms
|
||||
rustual-boy = {} # need game for testing
|
||||
scummvm = {} # need game for testing
|
||||
#vice = {} # broken on new toolchain
|
||||
|
||||
# Games
|
||||
devilutionx = {}
|
||||
eduke32 = {}
|
||||
freeciv = {}
|
||||
gigalomania = {}
|
||||
love = {}
|
||||
mednaffe = {}
|
||||
openjazz = {}
|
||||
openjk = {}
|
||||
openttd = {}
|
||||
openttd-opengfx = {}
|
||||
openttd-openmsx = {}
|
||||
openttd-opensfx = {}
|
||||
quakespasm = {}
|
||||
sm64ex = {}
|
||||
#spacecadetpinball = {} # not building
|
||||
#vvvvvv = {} # cannot find -lgcc_s
|
||||
|
||||
# Demos
|
||||
#cairodemo = {}
|
||||
cmatrix = {}
|
||||
cpal = {}
|
||||
gears = {}
|
||||
glutin = {}
|
||||
#glutin = {}
|
||||
#hematite = {} # not building
|
||||
iced = {}
|
||||
libcosmic = {}
|
||||
osdemo = {} # does not show anything
|
||||
#libcosmic = {}
|
||||
#osdemo = {} # does not show anything
|
||||
#pathfinder = {} # not building
|
||||
procedural-wallpapers-rs = {}
|
||||
#rust-cairo = {}
|
||||
#rust-cairo-demo = {}
|
||||
sdl2-gears = {}
|
||||
vttest = {}
|
||||
#webrender = {}
|
||||
winit = {}
|
||||
|
||||
# dev
|
||||
# MIDI
|
||||
generaluser-gs = {}
|
||||
timidity = {}
|
||||
|
||||
# Development
|
||||
autoconf = {}
|
||||
automake = {}
|
||||
#cookbook = {}
|
||||
@ -63,38 +93,4 @@ gnu-make = {}
|
||||
nasm = {}
|
||||
patch = {}
|
||||
pkg-config = {}
|
||||
rust = {}
|
||||
|
||||
# games
|
||||
devilutionx = {}
|
||||
eduke32 = {}
|
||||
flycast = {}
|
||||
freeciv = {}
|
||||
gigalomania = {}
|
||||
love = {}
|
||||
mednafen = {}
|
||||
mgba = {}
|
||||
openjazz = {}
|
||||
openjk = {}
|
||||
openttd = {}
|
||||
openttd-opengfx = {}
|
||||
openttd-openmsx = {}
|
||||
openttd-opensfx = {}
|
||||
quakespasm = {}
|
||||
#retroarch = {} # need to package cores
|
||||
rs-nes = {} # need game for testing
|
||||
rust64 = {} # need roms
|
||||
rustual-boy = {} # need game for testing
|
||||
scummvm = {} # need game for testing
|
||||
sm64ex = {}
|
||||
#spacecadetpinball = {} # not building
|
||||
syobonaction = {}
|
||||
#vice = {} # broken on new toolchain
|
||||
#vvvvvv = {} # cannot find -lgcc_s
|
||||
|
||||
# stuff
|
||||
generaluser-gs = {}
|
||||
jeremy = {}
|
||||
noto-color-emoji = {}
|
||||
timidity = {}
|
||||
ttf-hack = {}
|
||||
#rust = {}
|
||||
|
||||
@ -1,240 +0,0 @@
|
||||
diff -ruwN git-2.13.1/compat/bswap.h source/compat/bswap.h
|
||||
--- git-2.13.1/compat/bswap.h 2017-06-04 19:08:11.000000000 -0600
|
||||
+++ source/compat/bswap.h 2025-04-24 11:20:06.475749424 -0600
|
||||
@@ -1,3 +1,7 @@
|
||||
+#if defined(__redox__)
|
||||
+#include <machine/endian.h>
|
||||
+#endif
|
||||
+
|
||||
/*
|
||||
* Let's make sure we always have a sane definition for ntohl()/htonl().
|
||||
* Some libraries define those as a function call, just to perform byte
|
||||
diff -ruwN git-2.13.1/compat/terminal.c source/compat/terminal.c
|
||||
--- git-2.13.1/compat/terminal.c 2017-06-04 19:08:11.000000000 -0600
|
||||
+++ source/compat/terminal.c 2025-04-18 10:00:11.318697446 -0600
|
||||
@@ -137,6 +137,18 @@
|
||||
return buf.buf;
|
||||
}
|
||||
|
||||
+#elif defined(__redox__)
|
||||
+
|
||||
+ssize_t __getline(char **lptr, size_t *n, FILE *fp);
|
||||
+
|
||||
+char *git_terminal_prompt(const char *prompt, int echo)
|
||||
+{
|
||||
+ char *line = NULL;
|
||||
+ size_t n = 0;
|
||||
+ __getline(&line, &n, stdin);
|
||||
+ return line; // XXX leak
|
||||
+}
|
||||
+
|
||||
#else
|
||||
|
||||
char *git_terminal_prompt(const char *prompt, int echo)
|
||||
diff -ruwN git-2.13.1/configure source/configure
|
||||
--- git-2.13.1/configure 2017-06-04 19:08:11.000000000 -0600
|
||||
+++ source/configure 2025-04-18 10:00:11.318697446 -0600
|
||||
@@ -6156,7 +6156,7 @@
|
||||
ac_res=$ac_cv_search_getaddrinfo
|
||||
if test "$ac_res" != no; then :
|
||||
test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
|
||||
- NO_IPV6=
|
||||
+ NO_IPV6=YesPlease
|
||||
else
|
||||
NO_IPV6=YesPlease
|
||||
fi
|
||||
diff -ruwN git-2.13.1/daemon.c source/daemon.c
|
||||
--- git-2.13.1/daemon.c 2017-06-04 19:08:11.000000000 -0600
|
||||
+++ source/daemon.c 2025-04-18 10:00:11.319697447 -0600
|
||||
@@ -71,13 +71,21 @@
|
||||
return hi->ip_address.buf;
|
||||
}
|
||||
|
||||
+#if defined(__redox__)
|
||||
+#define LOG_ERR 0
|
||||
+#define LOG_INFO 1
|
||||
+#endif
|
||||
+
|
||||
static void logreport(int priority, const char *err, va_list params)
|
||||
{
|
||||
+#if !defined(__redox__)
|
||||
if (log_syslog) {
|
||||
char buf[1024];
|
||||
vsnprintf(buf, sizeof(buf), err, params);
|
||||
syslog(priority, "%s", buf);
|
||||
- } else {
|
||||
+ } else
|
||||
+#endif
|
||||
+ {
|
||||
/*
|
||||
* Since stderr is set to buffered mode, the
|
||||
* logging of different processes will not overlap
|
||||
@@ -888,8 +896,12 @@
|
||||
|
||||
if (!reuseaddr)
|
||||
return 0;
|
||||
+#if defined(__redox__)
|
||||
+ return 0;
|
||||
+#else
|
||||
return setsockopt(sockfd, SOL_SOCKET, SO_REUSEADDR,
|
||||
&on, sizeof(on));
|
||||
+#endif
|
||||
}
|
||||
|
||||
struct socketlist {
|
||||
@@ -1174,11 +1186,7 @@
|
||||
if (!group_name)
|
||||
c.gid = c.pass->pw_gid;
|
||||
else {
|
||||
- struct group *group = getgrnam(group_name);
|
||||
- if (!group)
|
||||
die("group not found - %s", group_name);
|
||||
-
|
||||
- c.gid = group->gr_gid;
|
||||
}
|
||||
|
||||
return &c;
|
||||
@@ -1348,10 +1356,12 @@
|
||||
usage(daemon_usage);
|
||||
}
|
||||
|
||||
+#if !defined(__redox__)
|
||||
if (log_syslog) {
|
||||
openlog("git-daemon", LOG_PID, LOG_DAEMON);
|
||||
set_die_routine(daemon_die);
|
||||
} else
|
||||
+#endif
|
||||
/* avoid splitting a message in the middle */
|
||||
setvbuf(stderr, NULL, _IOFBF, 4096);
|
||||
|
||||
diff -ruwN git-2.13.1/git-compat-util.h source/git-compat-util.h
|
||||
--- git-2.13.1/git-compat-util.h 2017-06-04 19:08:11.000000000 -0600
|
||||
+++ source/git-compat-util.h 2025-04-18 10:00:11.319697447 -0600
|
||||
@@ -1,6 +1,18 @@
|
||||
#ifndef GIT_COMPAT_UTIL_H
|
||||
#define GIT_COMPAT_UTIL_H
|
||||
|
||||
+#ifndef SIG_DFL
|
||||
+#define SIG_DFL ((void (*)(int))0)
|
||||
+#endif
|
||||
+
|
||||
+#ifndef SIG_IGN
|
||||
+#define SIG_IGN ((void (*)(int))1)
|
||||
+#endif
|
||||
+
|
||||
+#ifndef SIG_ERR
|
||||
+#define SIG_ERR ((void (*)(int))-1)
|
||||
+#endif
|
||||
+
|
||||
#define _FILE_OFFSET_BITS 64
|
||||
|
||||
|
||||
@@ -323,6 +335,14 @@
|
||||
#define PATH_SEP ':'
|
||||
#endif
|
||||
|
||||
+#ifndef DEV_NULL
|
||||
+#if defined(__redox__)
|
||||
+#define DEV_NULL "/scheme/null"
|
||||
+#else
|
||||
+#define DEV_NULL "/dev/null"
|
||||
+#endif
|
||||
+#endif
|
||||
+
|
||||
#ifdef HAVE_PATHS_H
|
||||
#include <paths.h>
|
||||
#endif
|
||||
diff -ruwN git-2.13.1/Makefile source/Makefile
|
||||
--- git-2.13.1/Makefile 2017-06-05 08:08:11.000000000 +0700
|
||||
+++ source/Makefile 2025-09-01 04:41:10.339224568 +0700
|
||||
@@ -979,7 +979,7 @@
|
||||
BUILTIN_OBJS += builtin/write-tree.o
|
||||
|
||||
GITLIBS = common-main.o $(LIB_FILE) $(XDIFF_LIB)
|
||||
-EXTLIBS =
|
||||
+EXTLIBS = -lnghttp2
|
||||
|
||||
GIT_USER_AGENT = git/$(GIT_VERSION)
|
||||
|
||||
@@ -1802,7 +1802,6 @@
|
||||
|
||||
$(BUILT_INS): git$X
|
||||
$(QUIET_BUILT_IN)$(RM) $@ && \
|
||||
- ln $< $@ 2>/dev/null || \
|
||||
ln -s $< $@ 2>/dev/null || \
|
||||
cp $< $@
|
||||
|
||||
@@ -2096,7 +2095,6 @@
|
||||
|
||||
$(REMOTE_CURL_ALIASES): $(REMOTE_CURL_PRIMARY)
|
||||
$(QUIET_LNCP)$(RM) $@ && \
|
||||
- ln $< $@ 2>/dev/null || \
|
||||
ln -s $< $@ 2>/dev/null || \
|
||||
cp $< $@
|
||||
|
||||
@@ -2449,14 +2447,12 @@
|
||||
for p in $(filter $(install_bindir_programs),$(BUILT_INS)); do \
|
||||
$(RM) "$$bindir/$$p" && \
|
||||
test -z "$(NO_INSTALL_HARDLINKS)" && \
|
||||
- ln "$$bindir/git$X" "$$bindir/$$p" 2>/dev/null || \
|
||||
ln -s "git$X" "$$bindir/$$p" 2>/dev/null || \
|
||||
cp "$$bindir/git$X" "$$bindir/$$p" || exit; \
|
||||
done && \
|
||||
for p in $(BUILT_INS); do \
|
||||
$(RM) "$$execdir/$$p" && \
|
||||
test -z "$(NO_INSTALL_HARDLINKS)" && \
|
||||
- ln "$$execdir/git$X" "$$execdir/$$p" 2>/dev/null || \
|
||||
ln -s "git$X" "$$execdir/$$p" 2>/dev/null || \
|
||||
cp "$$execdir/git$X" "$$execdir/$$p" || exit; \
|
||||
done && \
|
||||
@@ -2464,7 +2460,6 @@
|
||||
for p in $$remote_curl_aliases; do \
|
||||
$(RM) "$$execdir/$$p" && \
|
||||
test -z "$(NO_INSTALL_HARDLINKS)" && \
|
||||
- ln "$$execdir/git-remote-http$X" "$$execdir/$$p" 2>/dev/null || \
|
||||
ln -s "git-remote-http$X" "$$execdir/$$p" 2>/dev/null || \
|
||||
cp "$$execdir/git-remote-http$X" "$$execdir/$$p" || exit; \
|
||||
done && \
|
||||
diff -ruwN git-2.13.1/run-command.c source/run-command.c
|
||||
--- git-2.13.1/run-command.c 2017-06-04 19:08:11.000000000 -0600
|
||||
+++ source/run-command.c 2025-04-18 10:00:11.320697447 -0600
|
||||
@@ -120,9 +120,9 @@
|
||||
#ifndef GIT_WINDOWS_NATIVE
|
||||
static inline void dup_devnull(int to)
|
||||
{
|
||||
- int fd = open("/dev/null", O_RDWR);
|
||||
+ int fd = open(DEV_NULL, O_RDWR);
|
||||
if (fd < 0)
|
||||
- die_errno(_("open /dev/null failed"));
|
||||
+ die_errno(_("open %s failed"), DEV_NULL);
|
||||
if (dup2(fd, to) < 0)
|
||||
die_errno(_("dup2(%d,%d) failed"), fd, to);
|
||||
close(fd);
|
||||
diff -ruwN git-2.13.1/setup.c source/setup.c
|
||||
--- git-2.13.1/setup.c 2017-06-05 08:08:11.000000000 +0700
|
||||
+++ source/setup.c 2025-09-01 04:41:10.339224568 +0700
|
||||
@@ -1146,11 +1146,11 @@
|
||||
/* if any standard file descriptor is missing open it to /dev/null */
|
||||
void sanitize_stdfds(void)
|
||||
{
|
||||
- int fd = open("/dev/null", O_RDWR, 0);
|
||||
+ int fd = open(DEV_NULL, O_RDWR, 0);
|
||||
while (fd != -1 && fd < 2)
|
||||
fd = dup(fd);
|
||||
if (fd == -1)
|
||||
- die_errno("open /dev/null or dup failed");
|
||||
+ die_errno("open %s or dup failed", DEV_NULL);
|
||||
if (fd > 2)
|
||||
close(fd);
|
||||
}
|
||||
@@ -1169,8 +1169,10 @@
|
||||
default:
|
||||
exit(0);
|
||||
}
|
||||
+#if !defined(__redox__)
|
||||
if (setsid() == -1)
|
||||
die_errno("setsid failed");
|
||||
+#endif
|
||||
close(0);
|
||||
close(1);
|
||||
close(2);
|
||||
2
recipes/dev/git/gitconfig
Normal file
2
recipes/dev/git/gitconfig
Normal file
@ -0,0 +1,2 @@
|
||||
[protocol]
|
||||
version = 0
|
||||
@ -1,15 +1,13 @@
|
||||
[source]
|
||||
tar = "https://www.kernel.org/pub/software/scm/git/git-2.13.1.tar.xz"
|
||||
blake3 = "bc78271bffd60c5b8b938d8c08fd74dc2de8d21fbaf8f8e0e3155436d9263f17"
|
||||
patches = ["git.patch"]
|
||||
tar = "https://www.kernel.org/pub/software/scm/git/git-2.56.0.tar.xz"
|
||||
blake3 = "596b02fea3d67e2ca45208aabebc92d2c14e7f2827f82cba59a630d55eea0854"
|
||||
|
||||
[build]
|
||||
dependencies=[
|
||||
"curl",
|
||||
"expat",
|
||||
"nghttp2",
|
||||
"openssl3",
|
||||
"zlib"
|
||||
"zlib",
|
||||
"pcre2",
|
||||
]
|
||||
template = "custom"
|
||||
script = """
|
||||
@ -18,36 +16,34 @@ DYNAMIC_INIT
|
||||
MAKEFLAGS=(
|
||||
NEEDS_SSL_WITH_CURL=1
|
||||
NEEDS_CRYPTO_WITH_SSL=1
|
||||
NO_IPV6=1
|
||||
NO_PREAD=1
|
||||
NO_MMAP=1
|
||||
NO_SETITIMER=1
|
||||
NO_UNIX_SOCKETS=1
|
||||
NO_IPV6=1 # not implemented
|
||||
NO_MMAP=1 # mmap writes extra null padding
|
||||
NO_SETITIMER=1 # deprecated
|
||||
NO_UNIX_SOCKETS=1 # need inotify
|
||||
NEEDS_LIBICONV=
|
||||
NEEDS_LIBRT=
|
||||
BLK_SHA1=1
|
||||
V=1
|
||||
RUST_TARGETS=$TARGET
|
||||
INSTALL_SYMLINKS=1
|
||||
)
|
||||
|
||||
if [ "${COOKBOOK_DYNAMIC}" != "1" ]; then
|
||||
# git does not use pkgconfig to be aware with zstd
|
||||
MAKEFLAGS+=( EXTLIBS="-lzstd -lnghttp2 -lz" )
|
||||
fi
|
||||
|
||||
export CURL_CONFIG="${COOKBOOK_SYSROOT}/usr/bin/curl-config"
|
||||
./configure \
|
||||
--host="${GNU_TARGET}" \
|
||||
--prefix=/usr \
|
||||
--sysconfdir=/etc \
|
||||
ac_cv_fread_reads_directories=yes \
|
||||
ac_cv_snprintf_returns_bogus=yes \
|
||||
ac_cv_lib_curl_curl_global_init=yes
|
||||
"${COOKBOOK_MAKE}" "${MAKEFLAGS[@]}" -j"${COOKBOOK_MAKE_JOBS}"
|
||||
"${COOKBOOK_MAKE}" DESTDIR="${COOKBOOK_STAGE}" "${MAKEFLAGS[@]}" install
|
||||
rm -rf "${COOKBOOK_STAGE}/usr/share/man"
|
||||
|
||||
# TODO: pinned to protocol v0 otherwise silently quit
|
||||
mkdir -p "${COOKBOOK_STAGE}/etc"
|
||||
cp "${COOKBOOK_RECIPE}/gitconfig" "${COOKBOOK_STAGE}/etc/"
|
||||
"""
|
||||
|
||||
[package]
|
||||
dependencies = [
|
||||
"ca-certificates",
|
||||
"nghttp2"
|
||||
]
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
#TODO add script for gnu make: https://github.com/ip7z/7zip/blob/main/DOC/readme.txt#L110
|
||||
[source]
|
||||
tar = "https://7-zip.org/a/7z2605-src.tar.xz"
|
||||
tar = "https://github.com/ip7z/7zip/releases/download/26.05/7z2605-src.tar.xz"
|
||||
[build]
|
||||
template = "cmake"
|
||||
|
||||
@ -1,7 +1,9 @@
|
||||
#TODO: Incomplete std/syscall porting, or vendor patches
|
||||
#TODO: unable to init TUI due to bugs in pty
|
||||
[source]
|
||||
git = "https://github.com/jesseduffield/lazygit"
|
||||
git = "https://github.com/willnode/lazygit"
|
||||
branch = "redox"
|
||||
shallow_clone = true
|
||||
|
||||
[build]
|
||||
template = "custom"
|
||||
dev-dependencies = [
|
||||
@ -21,3 +23,8 @@ esac
|
||||
mkdir -p $COOKBOOK_STAGE/usr/bin
|
||||
go build -C ${COOKBOOK_SOURCE} -o $COOKBOOK_STAGE/usr/bin/lazygit
|
||||
"""
|
||||
|
||||
[package]
|
||||
dependencies = [
|
||||
"git"
|
||||
]
|
||||
|
||||
@ -7,6 +7,7 @@ shallow_clone = true
|
||||
[build]
|
||||
template = "custom"
|
||||
script = """
|
||||
COOKBOOK_NOSTRIP=1
|
||||
export PATH=$HOME/.local/go/bin:$PATH
|
||||
|
||||
export GOPATH=${COOKBOOK_BUILD}/gopath
|
||||
@ -31,7 +32,7 @@ case "${TARGET}" in
|
||||
riscv64gc-unknown-redox) export GOARCH=riscv64 GOOS=redox;;
|
||||
esac
|
||||
|
||||
export CGO_ENABLED=1
|
||||
export CC=gcc CXX=g++ CGO_ENABLED=0
|
||||
echo "go1.27.3" > VERSION # to set -trimpath
|
||||
(cd ./src && bash ./make.bash)
|
||||
|
||||
|
||||
@ -1,9 +1,17 @@
|
||||
#TODO fix secmem-proc crate
|
||||
[source]
|
||||
git = "https://gitlab.torproject.org/tpo/core/arti"
|
||||
rev = "arti-v2.7.0"
|
||||
shallow_clone = true
|
||||
# TODO: Check if this patch is still necessary after
|
||||
# we've updated our Rust toolchains on Redox.
|
||||
patches = ["redox.patch"]
|
||||
[build]
|
||||
template = "cargo"
|
||||
# TODO: Remove `static-sqlite` feature once Redox' sqlite3-package is fully functional.
|
||||
cargoflags = [
|
||||
"--no-default-features",
|
||||
"--features=default-runtime,dns-proxy,compression,bridge-client,pt-client,onion-service-client,vanguards,flowctl-cc,static-sqlite",
|
||||
]
|
||||
cargopackages = ["arti"]
|
||||
dependencies = [
|
||||
"openssl3",
|
||||
|
||||
38
recipes/wip/net/onion-routing/arti/redox.patch
Normal file
38
recipes/wip/net/onion-routing/arti/redox.patch
Normal file
@ -0,0 +1,38 @@
|
||||
diff --git a/crates/fslock-guard/Cargo.toml b/crates/fslock-guard/Cargo.toml
|
||||
index 9cbffb2c..2fd42d35 100644
|
||||
--- a/crates/fslock-guard/Cargo.toml
|
||||
+++ b/crates/fslock-guard/Cargo.toml
|
||||
@@ -24,2 +24,2 @@
|
||||
-[target.'cfg(target_os = "android")'.dependencies]
|
||||
+[target.'cfg(any(target_os = "android", target_os = "redox"))'.dependencies]
|
||||
libc = "0.2"
|
||||
diff --git a/crates/fslock-guard/src/lib.rs b/crates/fslock-guard/src/lib.rs
|
||||
index b5e938bb..7c32168c 100644
|
||||
--- a/crates/fslock-guard/src/lib.rs
|
||||
+++ b/crates/fslock-guard/src/lib.rs
|
||||
@@ -177,7 +177,7 @@ impl Drop for LockFileGuard {
|
||||
/// Try to lock `f`, blocking if need be.
|
||||
///
|
||||
/// On non-android, this just calls [`fs::File::lock`].
|
||||
-#[cfg(not(target_os = "android"))]
|
||||
+#[cfg(not(any(target_os = "android", target_os = "redox")))]
|
||||
fn do_lock(f: &fs::File) -> std::io::Result<()> {
|
||||
f.lock()
|
||||
}
|
||||
@@ -185,7 +185,7 @@ fn do_lock(f: &fs::File) -> std::io::Result<()> {
|
||||
/// Try to lock `f`, without blocking.
|
||||
///
|
||||
/// On non-android, this just calls [`fs::File::try_lock`].
|
||||
-#[cfg(not(target_os = "android"))]
|
||||
+#[cfg(not(any(target_os = "android", target_os = "redox")))]
|
||||
fn do_try_lock(f: &fs::File) -> Result<(), std::fs::TryLockError> {
|
||||
f.try_lock()
|
||||
}
|
||||
@@ -207,2 +207,2 @@
|
||||
-#[cfg(target_os = "android")]
|
||||
+#[cfg(any(target_os = "android", target_os = "redox"))]
|
||||
fn do_lock(f: &fs::File) -> std::io::Result<()> {
|
||||
@@ -234,2 +234,2 @@
|
||||
-#[cfg(target_os = "android")]
|
||||
+#[cfg(any(target_os = "android", target_os = "redox"))]
|
||||
fn do_try_lock(f: &fs::File) -> Result<(), std::fs::TryLockError> {
|
||||
Loading…
Reference in New Issue
Block a user