Skip to content

Instantly share code, notes, and snippets.

View knz's full-sized avatar
🇳🇱

Raphael 'kena' Poss knz

🇳🇱
View GitHub Profile
## -*- Shell-script -*-
##
## zshrc
##
umask 022
setopt correct
setopt auto_continue
setopt hist_ignore_dups
@knz
knz / build.log
Created June 13, 2022 20:32
bazel build log
INFO: Invocation ID: f04dc13f-6f57-4be9-84cf-371d667004dd
Loading:
Loading: 0 packages loaded
INFO: Build options --//build/toolchains:nogo_flag and --//build/toolchains:nonogo_explicit_flag have changed, discarding analysis cache.
Analyzing: target //pkg/cmd/cockroach:cockroach (0 packages loaded, 0 targets configured)
INFO: ToolchainResolution: Target platform @local_config_platform//:host: Selected execution platform @local_config_platform//:host,
INFO: ToolchainResolution: Type @io_bazel_rules_go//go:toolchain: target platform @local_config_platform//:host: Rejected toolchain @go_sdk//:go_aix_ppc64-impl; mismatching values: aix, ppc64
INFO: ToolchainResolution: Type @io_bazel_rules_go//go:toolchain: target platform @local_config_platform//:host: Rejected toolchain @go_sdk//:go_android_386-impl; mismatching values: android, x86_32
INFO: ToolchainResolution: Type @io_bazel_rules_go//go:toolchain: target platform @local_config_platform//:host: Rejected toolchain @go_sdk//:go_android_amd64-impl;
# make kernel -j8
...
--- linux_device.o ---
In file included from /data/usr/local/sys/modules/drm-current-kmod/linuxkpi/gplv2/src/linux_device.c:2:
/data/usr/local/sys/modules/drm-current-kmod/linuxkpi/gplv2/include/linux/pci.h:51:1: error: redefinition of 'pci_bus_read_config'
pci_bus_read_config(struct pci_bus *bus, unsigned int devfn,
^
/data/usr/src/sys/compat/linuxkpi/common/include/linux/pci.h:1101:1: note: previous definition is here
pci_bus_read_config(struct pci_bus *bus, unsigned int devfn,
^
@knz
knz / bzl.diff
Created December 28, 2020 19:24
make bazel-generate && git diff
diff --git a/pkg/base/BUILD.bazel b/pkg/base/BUILD.bazel
index c0370613c6..98a0c3c360 100644
--- a/pkg/base/BUILD.bazel
+++ b/pkg/base/BUILD.bazel
@@ -52,7 +52,7 @@ go_test(
"store_spec_test.go",
],
deps = [
- ":base",
+ "//pkg/base",
kena@kenux ....com/cockroachdb/cockroach % build/builder.sh mkrelease amd64-linux-musl
+ CGO_ENABLED=1
+ make BUILDTYPE=release XGOOS=linux XGOARCH=amd64 XCMAKE_SYSTEM_NAME=Linux TARGET_TRIPLE=x86_64-unknown-linux-musl LDFLAGS=-static SUFFIX=-linux-2.6.32-musl-amd64
Running make with -j8
GOPATH set to /go
rm -rf /go/native/x86_64-pc-linux-gnu/protobuf
mkdir -p /go/native/x86_64-pc-linux-gnu/protobuf
cd /go/native/x86_64-pc-linux-gnu/protobuf && cmake  -Dprotobuf_BUILD_TESTS=OFF /go/src/github.com/cockroachdb/cockroach/c-deps/protobuf/cmake \
  -DCMAKE_BUILD_TYPE=Release
@knz
knz / pr.diff
Last active July 17, 2018 12:38
diff --git a/pkg/cli/sql.go b/pkg/cli/sql.go
index 5957fae4bb..160f5edeec 100644
--- a/pkg/cli/sql.go
+++ b/pkg/cli/sql.go
@@ -53,7 +53,7 @@ const (
`
)
-const defaultPromptPattern = "%n@%M/%?%x>"
+const defaultPromptPattern = "%n@%M/%/%x>"
@knz
knz / go1.6.2.parbuild.diff
Created June 8, 2016 15:42
cgo parallel build
--- src/cmd/go/build.go.orig 2016-06-08 15:34:08.613910443 +0000
+++ src/cmd/go/build.go 2016-06-08 15:38:07.317612174 +0000
@@ -694,6 +694,8 @@
exec sync.Mutex
readySema chan bool
ready actionQueue
+
+ tasks chan func()
}
use std::marker::PhantomFn;
trait Tr<T> : PhantomFn<(Self,T)> { type O; }
trait Hello : PhantomFn<Self> {
fn pr<A>(x : A) -> <Self as Tr<A>>::O where Self : Tr<A>;
fn ap<'a, A, B, F : Fn(A)->B> (f : <Self as Tr<&'a F>>::O, x : <Self as Tr<A>>::O) -> <Self as Tr<B>>::O
where Self : Tr<A> + Tr<B> + Tr<&'a F>;