Skip to content

Instantly share code, notes, and snippets.

View runlevel5's full-sized avatar

Trung Lê runlevel5

View GitHub Profile
@runlevel5
runlevel5 / zig-0.15.2-ppc64le.log
Created October 17, 2025 00:48
Full compilation log of zig 0.15.2 on Linux PPC64LE (Fedora 43)
[tle@fedora ~/W/zig]$ git diff
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0ab8e1cddd..eb2f60dbf1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -793,7 +793,7 @@ if(MSVC)
else()
set(ZIG_WASM2C_COMPILE_FLAGS "-std=c99 -O2")
set(ZIG1_COMPILE_FLAGS "-std=c99 -Os")
- set(ZIG2_COMPILE_FLAGS "-std=c99 -O0 -fno-sanitize=undefined -fno-stack-protector")
@runlevel5
runlevel5 / fish_toolbx.md
Last active September 17, 2025 13:21
How to have the special toolbox prompt for fish shell?

So if you happen to use fish shell for your toolbox container environment, you should set the fish_prompt by modify ~/.config/fish/config.fish:

if status is-interactive
  # Commands to run in interactive sessions can go here
  function is_toolbox
    if test -f /run/.toolboxenv
      set toolbox_name (grep -E '^name="' /run/.containerenv | cut -d \" -f 2)
      echo " ❱ $toolbox_name"
 end
@runlevel5
runlevel5 / instructions.md
Last active September 12, 2025 09:36
How to replace GNU coreutils with Rust uutils/coreutils locally in your user account in Fedora?

Run following bash script:

#!/bin/bash

# For binaries
SRC_BIN_DIR="/usr/bin"
DEST_BIN_DIR="$HOME/.local/uubin"

# Ensure destination directory exists
commit 3b6664a217eaea1ddb00dd978a5326b14ca57fa4
Author: Trung Lê <[email protected]>
Date: Tue Aug 12 11:27:43 2025 +1000
new version 2.3.8
diff --git a/.gitignore b/.gitignore
index 8a39d88..d6d11eb 100644
--- a/.gitignore
+++ b/.gitignore
@runlevel5
runlevel5 / cde-9f0f015c4daf7d3eacb21c19b4f3912cac56e68e-f43.log
Created August 11, 2025 23:03
CDE sha-9f0f015c4daf7d3eacb21c19b4f3912cac56e68e compilation error on Fedora 43
$ export CC='gcc -std=c90'
$ ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether sleep supports fractional seconds... yes
checking filesystem timestamp resolution... 0.1
checking whether build environment is sane... yes
checking for a race-free mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
@runlevel5
runlevel5 / gcc15_fix_issort_compfunc.patch
Last active March 31, 2025 01:34
Common Desktop Environment: Fix Issort compare function definition
diff --git a/cde/lib/tt/mini_isam/isam_impl.h b/cde/lib/tt/mini_isam/isam_impl.h
index 8172077da..c11ac7820 100644
--- a/cde/lib/tt/mini_isam/isam_impl.h
+++ b/cde/lib/tt/mini_isam/isam_impl.h
@@ -381,7 +381,7 @@ typedef struct issort {
/* many records */
int ist_nrecs; /* number of records inserted */
int ist_currec; /* current position */
- int (*ist_compf) (); /* comparison function */
+ int (*ist_compf) (const void *, const void *); /* comparison function */
@runlevel5
runlevel5 / example.ign
Created March 24, 2025 13:36
Fedora coreos test ignition file
{
"ignition": {
"version": "3.5.0"
},
"passwd": {
"users": [
{
"name": "core",
"sshAuthorizedKeys": [
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCgyvCeNY1X7DmUPzLgpYoyIglrFT5YO40DIYoL9WuHFwdiXU0m8S+dnc2aGQ78XU6SJCUaOmg2uUnTqjYwf8JmwFmTp9iil4qmw+opudUFZw+Yh6MFQt9aC68YWxa3b+NxbHK4ouNFO4ODTgPcHdmK5ENX1TNvb8xxMlPAxpgfiQKHiJL4ItcZZiVDmx9sMJRNqJ4REV4ZyyzotRRXAsThjm4rVSg95jbfl4UEnTfd23K8k5zhAuwPf84NlhlEdwuCxpWmGmSJ0QgMh6076bSC1+d9nMKU8xY9oX4NiVvdaJHL2dLdrhLh7CZ9efUeOVcJ4spKM1wJCW4Btt8Sj [email protected]"
@runlevel5
runlevel5 / org.lwjgl3.json
Last active June 20, 2024 14:38
Minecraft 1.21 LWJGL3 config for Linux PPC64LE (for PrismLauncher)
{
"formatVersion": 1,
"libraries": [
{
"downloads": {
"artifact": {
"sha1": "a9479c9d1daa4061e2052ca02c937dcad5edeac3",
"size": 451935,
"url": "https://raw.githubusercontent.com/runlevel5/lwjgl3-ppc64le-release/main/3.3.3/lwjgl-freetype-3.3.3.jar"
}
@runlevel5
runlevel5 / 6600xt_benchmarking.md
Last active June 15, 2024 02:35
AMD Radeon RX 6600 XT Linux 6.8.11 benchmarking
$ vkmark
=======================================================
    vkmark 2017.08
=======================================================
    Vendor ID:      0x1002
    Device ID:      0x73FF
    Device Name:    AMD Radeon RX 6600 XT (RADV NAVI23)
    Driver Version: 100667393
    Device UUID:    71ea6a78fd227b69198285fd621ab941
@runlevel5
runlevel5 / list_all_versions_grouped_by_package.bash
Last active November 22, 2022 22:50
Just a quick script to create a JSON of which key is the NPM package name and value is the array of all versions
#!/bin/bash
set -euo pipefail
PACKAGE="null"
packages_filepath="packages"
detailed_packages_filepath="detailed_packages"
username="shortlyster"
CLEANUP="false"
main() {