mirror of
https://gitlab.redox-os.org/redox-os/redox.git
synced 2026-07-07 12:09:00 +08:00
Compare commits
24 Commits
a4eacb7a55
...
a4361fce6f
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a4361fce6f | ||
|
|
c8c07c711b | ||
|
|
e5ef805f38 | ||
|
|
12bb45c50c | ||
|
|
db63dae187 | ||
|
|
6eda4b8aac | ||
|
|
4f2efe1c56 | ||
|
|
16e98e3f28 | ||
|
|
716cca1b4e | ||
|
|
0373415174 | ||
|
|
ef6bf9beff | ||
|
|
b6cac36159 | ||
|
|
f617c5bc6c | ||
|
|
2498e4bfb3 | ||
|
|
0e232a7909 | ||
|
|
1c93c89f38 | ||
|
|
778af4cdcc | ||
|
|
1a0b0f129a | ||
|
|
9114ec3cf1 | ||
|
|
104d1d6b82 | ||
|
|
91c38535df | ||
|
|
6659fe61a1 | ||
|
|
c46cbf857b | ||
|
|
134bc3d507 |
2
Makefile
2
Makefile
@ -101,7 +101,7 @@ gdb: FORCE
|
||||
# has started or you need to debug the interaction between the application and the kernel.
|
||||
# tl;dr: DO NOT USE THIS TARGET UNLESS YOU HAVE TO
|
||||
gdb-userspace: FORCE
|
||||
rust-gdb $(GDB_APP_FILE) --eval-command="add-symbol-file $(GDB_KERNEL_FILE) 0x$(shell readelf -S $(GDB_KERNEL_FILE) | grep .text | cut -c43-58)" --eval-command="target remote :1234"
|
||||
rust-gdb $(GDB_APP_FILE) --eval-command="add-symbol-file $(GDB_KERNEL_FILE)" --eval-command="target remote :1234"
|
||||
|
||||
# An empty target
|
||||
FORCE:
|
||||
|
||||
2
cookbook
2
cookbook
@ -1 +1 @@
|
||||
Subproject commit fc48fb9cf460833a91d0fd76911b39c1ef9d57bf
|
||||
Subproject commit 6e527b4350a0d02993d04e95e32f040cf5a32c72
|
||||
12
mk/disk.mk
12
mk/disk.mk
@ -1,6 +1,9 @@
|
||||
# Configuration file with the commands configuration of the Redox image
|
||||
|
||||
$(BUILD)/harddrive.img: $(HOST_FSTOOLS) $(REPO_TAG)
|
||||
ifeq ($(PODMAN_BUILD),1)
|
||||
$(PODMAN_RUN) make $@
|
||||
else
|
||||
mkdir -p $(BUILD)
|
||||
rm -rf $@ $@.partial
|
||||
-$(FUMOUNT) /tmp/redox_installer || true
|
||||
@ -11,8 +14,12 @@ $(BUILD)/harddrive.img: $(HOST_FSTOOLS) $(REPO_TAG)
|
||||
truncate -s "$$FILESYSTEM_SIZE"m $@.partial
|
||||
umask 002 && $(INSTALLER) $(INSTALLER_OPTS) -c $(FILESYSTEM_CONFIG) $@.partial
|
||||
mv $@.partial $@
|
||||
endif
|
||||
|
||||
$(BUILD)/redox-live.iso: $(HOST_FSTOOLS) $(REPO_TAG) redox.ipxe
|
||||
ifeq ($(PODMAN_BUILD),1)
|
||||
$(PODMAN_RUN) make $@
|
||||
else
|
||||
mkdir -p $(BUILD)
|
||||
rm -rf $@ $@.partial
|
||||
-$(FUMOUNT) /tmp/redox_installer || true
|
||||
@ -24,8 +31,12 @@ $(BUILD)/redox-live.iso: $(HOST_FSTOOLS) $(REPO_TAG) redox.ipxe
|
||||
umask 002 && $(INSTALLER) $(INSTALLER_OPTS) -c $(FILESYSTEM_CONFIG) --write-bootloader="$(BUILD)/bootloader-live.efi" --live $@.partial
|
||||
mv $@.partial $@
|
||||
cp redox.ipxe $(BUILD)/redox.ipxe
|
||||
endif
|
||||
|
||||
$(BUILD)/filesystem.img: $(HOST_FSTOOLS) $(REPO_TAG)
|
||||
ifeq ($(PODMAN_BUILD),1)
|
||||
$(PODMAN_RUN) make $@
|
||||
else
|
||||
mkdir -p $(BUILD)
|
||||
-$(FUMOUNT) $(BUILD)/filesystem/ || true
|
||||
rm -rf $@ $@.partial $(BUILD)/filesystem/
|
||||
@ -45,6 +56,7 @@ $(BUILD)/filesystem.img: $(HOST_FSTOOLS) $(REPO_TAG)
|
||||
-$(FUMOUNT) $(BUILD)/filesystem/ || true
|
||||
rm -rf $(BUILD)/filesystem/
|
||||
mv $@.partial $@
|
||||
endif
|
||||
|
||||
mount: $(HOST_FSTOOLS) FORCE
|
||||
mkdir -p $(BUILD)/filesystem/
|
||||
|
||||
@ -16,12 +16,16 @@ endif
|
||||
|
||||
## The installer and redoxfs run on the host, even when using Podman build
|
||||
$(HOST_FSTOOLS): installer redoxfs
|
||||
ifeq ($(PODMAN_BUILD),1)
|
||||
$(PODMAN_RUN) make $@
|
||||
else
|
||||
rm -rf $@ $@.partial
|
||||
mkdir -p $@.partial
|
||||
$(HOST_CARGO) install --root $@.partial --path installer --bin redox_installer
|
||||
$(HOST_CARGO) install --root $@.partial --path redoxfs --bin redoxfs --bin redoxfs-mkfs
|
||||
mv $@.partial $@
|
||||
touch $@
|
||||
endif
|
||||
|
||||
fstools_clean: FORCE $(CONTAINER_TAG)
|
||||
ifeq ($(PODMAN_BUILD),1)
|
||||
|
||||
12
mk/podman.mk
12
mk/podman.mk
@ -17,15 +17,15 @@ endif
|
||||
## Podman Home Directory
|
||||
PODMAN_HOME?=$(ROOT)/build/podman
|
||||
## Podman command with its many arguments
|
||||
PODMAN_VOLUMES?=--volume $(ROOT):$(CONTAINER_WORKDIR)$(PODMAN_VOLUME_FLAG) --volume $(PODMAN_HOME):/home$(PODMAN_VOLUME_FLAG)
|
||||
PODMAN_ENV?=--env PATH=/home/poduser/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin --env PODMAN_BUILD=0
|
||||
PODMAN_VOLUMES?=--volume $(ROOT):$(CONTAINER_WORKDIR)$(PODMAN_VOLUME_FLAG) --volume $(PODMAN_HOME):/root$(PODMAN_VOLUME_FLAG)
|
||||
PODMAN_ENV?=--env PATH=/root/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin --env PODMAN_BUILD=0
|
||||
PODMAN_CONFIG?=--env ARCH=$(ARCH) --env BOARD=$(BOARD) --env CONFIG_NAME=$(CONFIG_NAME) --env FILESYSTEM_CONFIG=$(FILESYSTEM_CONFIG)
|
||||
PODMAN_OPTIONS?=--rm --workdir $(CONTAINER_WORKDIR) --userns keep-id --user `id -u` --interactive --tty --env TERM=$(TERM)
|
||||
PODMAN_OPTIONS?=--rm --workdir $(CONTAINER_WORKDIR) --interactive --tty --cap-add SYS_ADMIN --device /dev/fuse --env TERM=$(TERM)
|
||||
PODMAN_RUN?=podman run $(PODMAN_OPTIONS) $(PODMAN_VOLUMES) $(PODMAN_ENV) $(PODMAN_CONFIG) $(IMAGE_TAG)
|
||||
|
||||
container_shell: build/container.tag
|
||||
ifeq ($(PODMAN_BUILD),1)
|
||||
podman run $(PODMAN_VOLUMES) $(PODMAN_OPTIONS) $(PODMAN_ENV) --tty $(IMAGE_TAG) bash
|
||||
podman run $(PODMAN_VOLUMES) $(PODMAN_OPTIONS) $(PODMAN_ENV) $(IMAGE_TAG) bash
|
||||
else
|
||||
@echo PODMAN_BUILD=$(PODMAN_BUILD), please set it to 1 in mk/config.mk
|
||||
endif
|
||||
@ -56,12 +56,12 @@ container_kill: FORCE
|
||||
build/container.tag: $(CONTAINERFILE)
|
||||
ifeq ($(PODMAN_BUILD),1)
|
||||
rm -f build/container.tag
|
||||
@echo "If podman_home dir cannot be removed, remove with \"sudo rm\"."
|
||||
-chmod -R 0700 $(PODMAN_HOME) || true
|
||||
-rm -rf $(PODMAN_HOME) || true
|
||||
-podman image rm --force $(IMAGE_TAG) || true
|
||||
mkdir -p $(PODMAN_HOME)
|
||||
@echo "Building Podman image. This may take some time."
|
||||
sed s/_UID_/`id -u`/ $(CONTAINERFILE) | podman build --file - $(PODMAN_VOLUMES) --tag $(IMAGE_TAG)
|
||||
cat $(CONTAINERFILE) | podman build --file - $(PODMAN_VOLUMES) --tag $(IMAGE_TAG)
|
||||
@echo "Mapping Podman user space. Please wait."
|
||||
$(PODMAN_RUN) bash -e podman/rustinstall.sh
|
||||
mkdir -p build
|
||||
|
||||
@ -71,6 +71,9 @@ $(PREFIX)/relibc-install.tar.gz: $(PREFIX)/relibc-install
|
||||
.
|
||||
|
||||
$(PREFIX)/libtool:
|
||||
ifeq ($(PODMAN_BUILD),1)
|
||||
$(PODMAN_RUN) make $@
|
||||
else
|
||||
rm -rf "$@.partial" "$@"
|
||||
mkdir -p "$@.partial"
|
||||
|
||||
@ -85,6 +88,7 @@ $(PREFIX)/libtool:
|
||||
touch "$@.partial"
|
||||
echo $(LIBTOOL_VERSION) > $@.partial/.tarball-version
|
||||
mv "$@.partial" "$@"
|
||||
endif
|
||||
|
||||
$(PREFIX)/libtool-build: $(PREFIX)/libtool $(PREFIX)/rust-install
|
||||
ifeq ($(PODMAN_BUILD),1)
|
||||
@ -100,7 +104,7 @@ else
|
||||
--gnulib-srcdir=./gnulib
|
||||
PATH="$(ROOT)/$(PREFIX)/rust-install/bin:$$PATH" && \
|
||||
cd "$@.partial" && \
|
||||
cp -rp $(abspath $<)/. ./ && \
|
||||
cp -r $(abspath $<)/. ./ && \
|
||||
"$(ROOT)/$</configure" \
|
||||
--target="$(TARGET)" \
|
||||
--prefix=$(abspath $(PREFIX)/sysroot) && \
|
||||
|
||||
@ -22,6 +22,7 @@ ifeq ($(ARCH),i686)
|
||||
endif
|
||||
else ifeq ($(ARCH),x86_64)
|
||||
gpu?=vga
|
||||
uefi?=yes
|
||||
VGA_SUPPORTED=yes
|
||||
QEMU_ARCH=x86_64
|
||||
QEMU_MACHINE?=q35
|
||||
@ -90,7 +91,6 @@ else ifeq ($(ARCH),aarch64)
|
||||
endif
|
||||
else ifeq ($(ARCH),riscv64gc)
|
||||
live=no
|
||||
efi=yes
|
||||
audio=no
|
||||
gpu?=ramfb
|
||||
net=bridge
|
||||
@ -272,6 +272,9 @@ endif
|
||||
|
||||
ifeq ($(gdb),yes)
|
||||
QEMUFLAGS+=-d cpu_reset -s -S
|
||||
else ifeq ($(gdb),nonblock)
|
||||
# Allow attaching gdb, but don't block for it
|
||||
QEMUFLAGS+=-d cpu_reset -s
|
||||
endif
|
||||
|
||||
ifeq ($(UNAME),Linux)
|
||||
|
||||
@ -2,13 +2,8 @@
|
||||
|
||||
FROM debian:trixie
|
||||
|
||||
# _UID_ must be replaced with the user's uid on host
|
||||
# podman root is mapped to your user id on host during build,
|
||||
# poduser is mapped to your user id during podman run
|
||||
RUN useradd --create-home --no-log-init --uid _UID_ poduser \
|
||||
&& chown -R root:root /home \
|
||||
&& apt-get update \
|
||||
&& apt-get install -y --no-install-recommends \
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y --no-install-recommends \
|
||||
ant \
|
||||
appstream \
|
||||
appstream-compose \
|
||||
@ -36,7 +31,6 @@ RUN useradd --create-home --no-log-init --uid _UID_ poduser \
|
||||
gtk-doc-tools \
|
||||
help2man \
|
||||
intltool \
|
||||
libc6-dev-i386 \
|
||||
libexpat-dev \
|
||||
libfontconfig1-dev \
|
||||
libfuse3-dev \
|
||||
@ -72,7 +66,6 @@ RUN useradd --create-home --no-log-init --uid _UID_ poduser \
|
||||
ruby \
|
||||
scons \
|
||||
ssh \
|
||||
syslinux-utils \
|
||||
texinfo \
|
||||
unifdef \
|
||||
unzip \
|
||||
@ -84,4 +77,6 @@ RUN useradd --create-home --no-log-init --uid _UID_ poduser \
|
||||
xxd \
|
||||
zip \
|
||||
zlib1g-dev \
|
||||
zstd
|
||||
zstd; \
|
||||
if [ "$(dpkg --print-architecture)" = "amd64" ]; then \
|
||||
apt-get install -y --no-install-recommends libc6-dev-i386 syslinux-utils; fi
|
||||
|
||||
2
relibc
2
relibc
@ -1 +1 @@
|
||||
Subproject commit 92bc01247ad9c9ebae6e47740a1bb9e2f556635b
|
||||
Subproject commit fd9a1c9668c10d122eab9839d0f0f7f4d88703ab
|
||||
Loading…
Reference in New Issue
Block a user