Skip to content

Instantly share code, notes, and snippets.

@Lochnair
Lochnair / 1.4.5.xml
Created December 8, 2012 23:01
MauncherLoader MC 1.4.5 Patch XML
<?xml version="1.0" encoding="UTF-8"?>
<patches>
<patch name="net.minecraft.client.Minecraft">
<cmdarg name="datafolder" helptext="Folder to change .minecraft to">{MINECRAFT_DIR}</cmdarg>
<field name="an" type="java.io.File" protection="PUBLIC">new java.io.File("[datafolder]");</field>
<method name="b" protection="PUBLIC">return new java.io.File("[datafolder]");</method>
</patch>
<patch name="net.minecraft.src.ModLoader">
<field name="cfgdir" type="java.io.File" protection="PUBLIC">new java.io.File("[mlcfg]");</field>
@Lochnair
Lochnair / squid_3.5_with-ssl.patch
Last active August 8, 2016 20:31
Patch to enable SSL in Ubuntu Squid package
diff -r -U2 squid3-3.5.12-orig/debian/rules squid3-3.5.12/debian/rules
--- squid3-3.5.12-orig/debian/rules 2016-08-08 22:30:31.461962394 +0200
+++ squid3-3.5.12/debian/rules 2016-08-08 22:30:57.034275275 +0200
@@ -23,4 +23,6 @@
--enable-inline \
--disable-arch-native \
+ --enable-ssl \
+ --enable-ssl-crtd \
--enable-async-io=8 \
--enable-storeio="ufs,aufs,diskd,rock" \
@Lochnair
Lochnair / mips_toolchain.sh
Last active March 4, 2017 17:27 — forked from fgrep/wheezy-mips-toolchain
Debian wheezy mips(el) toolchain
#!/bin/sh
# Debian 7 MIPS Toolchain
ARCH=${ARCH:-mips}
# Update
mkdir /usr/src/$ARCH-toolchain && cd /usr/src/$ARCH-toolchain
apt-get update
apt-get upgrade
@Lochnair
Lochnair / gcc-4.7.2-musl.diff
Last active April 25, 2017 17:19
musl support for GCC 4.7.2
diff -r -U3 a/config.sub b/config.sub
--- a/config.sub 2017-04-25 18:33:42.050700561 +0200
+++ b/config.sub 2017-04-25 18:45:28.590275476 +0200
@@ -4,7 +4,7 @@
# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
# 2011 Free Software Foundation, Inc.
-timestamp='2011-10-29'
+timestamp='2011-03-23'
pipeline {
agent none
stages {
stage('Prepare') {
agent any
steps {
checkout scm: [$class: 'GitSCM', userRemoteConfigs: [[url: 'git://git.zx2c4.com/WireGuard']], branches: [[name: 'refs/tags/*']]], poll: true
sh 'git reset --hard'
From 00a970f9ce4a97e8f46f24c90c0242a658143457 Mon Sep 17 00:00:00 2001
From: Nils Andreas Svee <me@lochnair.net>
Date: Sun, 3 Mar 2019 23:44:16 +0100
Subject: [PATCH] Only use __vmalloc for now
---
src/compat/compat.h | 10 ----------
1 file changed, 10 deletions(-)
diff --git a/src/compat/compat.h b/src/compat/compat.h
From 00a970f9ce4a97e8f46f24c90c0242a658143457 Mon Sep 17 00:00:00 2001
From: Nils Andreas Svee <me@lochnair.net>
Date: Sun, 3 Mar 2019 23:44:16 +0100
Subject: [PATCH] Only use __vmalloc for now
---
src/compat/compat.h | 10 ----------
1 file changed, 10 deletions(-)
diff --git a/src/compat/compat.h b/src/compat/compat.h
@Lochnair
Lochnair / wg-jenkinsfile
Created May 19, 2019 10:13
wg-jenkinsfile
pipeline {
agent none
stages {
stage('Prepare') {
agent any
steps {
checkout scm: [$class: 'GitSCM', userRemoteConfigs: [[url: 'https://git.zx2c4.com/WireGuard']], branches: [[name: 'refs/tags/*']]], poll: true
sh 'git reset --hard'
#
# No change to .config
#
make[1]: Entering directory '/home/lochnair/Work/Network/openwrt-sdk-21.02.1-octeon_gcc-8.4.0_musl.Linux-x86_64'
make[2]: Entering directory '/home/lochnair/Work/Network/openwrt-sdk-21.02.1-octeon_gcc-8.4.0_musl.Linux-x86_64/package/toolchain'
echo "libc" >> /home/lochnair/Work/Network/openwrt-sdk-21.02.1-octeon_gcc-8.4.0_musl.Linux-x86_64/staging_dir/target-mips64_octeonplus_64_musl/pkginfo/toolchain.default.install
echo "libgcc" >> /home/lochnair/Work/Network/openwrt-sdk-21.02.1-octeon_gcc-8.4.0_musl.Linux-x86_64/staging_dir/target-mips64_octeonplus_64_musl/pkginfo/toolchain.default.install
echo "libpthread" >> /home/lochnair/Work/Network/openwrt-sdk-21.02.1-octeon_gcc-8.4.0_musl.Linux-x86_64/staging_dir/target-mips64_octeonplus_64_musl/pkginfo/toolchain.default.install
echo "librt" >> /home/lochnair/Work/Network/openwrt-sdk-21.02.1-octeon_gcc-8.4.0_musl.Linux-x86_64/staging_dir/target-mips64_octeonplus_64_musl/pkginfo/toolchain.default.install
touch -r /home/lochnair/Work/Network
WARNING: Makefile 'package/kernel/linux/Makefile' has a dependency on 'eip197-mini-firmware', which does not exist
WARNING: Makefile 'package/kernel/linux/Makefile' has a dependency on 'r8169-firmware', which does not exist
WARNING: Makefile 'package/kernel/linux/Makefile' has a dependency on 'e100-firmware', which does not exist
WARNING: Makefile 'package/kernel/linux/Makefile' has a dependency on 'bnx2-firmware', which does not exist
WARNING: Makefile 'package/kernel/linux/Makefile' has a dependency on 'bnx2x-firmware', which does not exist
WARNING: Makefile 'package/kernel/linux/Makefile' has a dependency on 'ar3k-firmware', which does not exist
WARNING: Makefile 'package/kernel/linux/Makefile' has a dependency on 'mwifiex-sdio-firmware', which does not exist
WARNING: Makefile 'package/kernel/linux/Makefile' has a dependency on 'kmod-phy-bcm-ns-usb2', which does not exist
WARNING: Makefile 'package/kernel/linux/Makefile' has a dependency on 'edgeport-firmware', which does not exist
WARNING: Makefile 'packa