Skip to content

Instantly share code, notes, and snippets.

@qbit
qbit / gist:1310855
Created October 25, 2011 00:01
despotify patch for openbsd
Index: src/lib/dns.c
===================================================================
--- src/lib/dns.c (revision 516)
+++ src/lib/dns.c (working copy)
@@ -12,7 +12,14 @@
#include <windns.h>
#elif defined __use_posix__
#include <arpa/nameser.h>
+#ifdef __use_openbsd__
+#define ns_c_in C_IN
@qbit
qbit / gist:1078137
Created July 12, 2011 14:54
npm install sqlite3 failed on debian squeeze
info it worked if it ends with ok
verbose cli [ 'node', '/usr/bin/npm', 'install', 'sqlite3' ]
info using npm@1.0.15
info using node@v0.4.9
verbose config file /home/qbit/.npmrc
verbose config file /usr/etc/npmrc
silly testEngine { name: 'application-name',
silly testEngine version: '0.0.1',
silly testEngine private: true,
silly testEngine dependencies: { express: '2.3.11', ejs: '>= 0.0.1' },
@qbit
qbit / npm_openbsd
Created May 1, 2011 16:06
openbsd npm install fix
diff --git a/lib/utils/tar.js b/lib/utils/tar.js
index 8c5bf94..ffa4ac1 100644
--- a/lib/utils/tar.js
+++ b/lib/utils/tar.js
@@ -167,11 +167,18 @@ function gunzTarPerm (tarball, tmp, dMode, fMode, uid, gid, cb) {
//console.error(npm.config.get("gzipbin")+" --decompress --stdout "
// +tarball+" | "+npm.config.get("tar")+" -mvxpf - --no-same-owner -C "
// +tmp)
+ var os = require("os");
+ var opts = [ "-mvxpf", "-", "--no-same-owner", "-C", tmp];