Skip to content

Instantly share code, notes, and snippets.

View mcg1969's full-sized avatar

Michael C. Grant mcg1969

  • Anaconda, Inc. / CVX Research Inc.
  • Austin, TX
View GitHub Profile
@mcg1969
mcg1969 / libtool.diff
Created January 7, 2014 16:43
This is a patch to the auto-generated libtool script that allows it to treat "-F*" arguments identically to "-L*" arguments. -F is used by Mac OSX to specify the path to frameworks that are not on the system path, in the same way that -L is used to specify paths to shared libraries.
--- libtool 2014-01-07 07:56:47.000000000 -0600
+++ libtool.mcg 2014-01-07 07:55:00.000000000 -0600
@@ -5982,13 +5982,17 @@
continue
;;
- -L*)
- func_stripname "-L" '' "$arg"
+ -L*|-F*)
+ case $arg in
@mcg1969
mcg1969 / octave.rb
Last active January 2, 2016 13:49
Preliminary Homebrew formula for Octave 3.8
require 'formula'
class Octave < Formula
homepage 'http://www.gnu.org/software/octave/index.html'
url 'http://ftpmirror.gnu.org/octave/octave-3.8.0.tar.bz2'
mirror 'http://ftp.gnu.org/gnu/octave/octave-3.8.0.tar.bz2'
sha1 'ebb03485b72d97fa01f105460f81016f94680f77'
# This isn't ready yet. But we're getting there.
# head 'http://hydra.nixos.org/job/gnu/octave-default/tarball/latest/download'
@mcg1969
mcg1969 / jit-typeinfo.diff
Last active January 2, 2016 16:09
Patch for libinterp/corefcn/jit-typeinfo.{cc,h}, Octave 3.8.0 build.
diff --git a/libinterp/corefcn/jit-typeinfo.cc b/libinterp/corefcn/jit-typeinfo.cc
index 77a3cf4..911f3b2 100644
--- a/libinterp/corefcn/jit-typeinfo.cc
+++ b/libinterp/corefcn/jit-typeinfo.cc
@@ -916,7 +916,7 @@ jit_operation::generate (const signature_vec&) const
bool
jit_operation::signature_cmp
-::operator() (const signature_vec *lhs, const signature_vec *rhs)
+::operator() (const signature_vec *lhs, const signature_vec *rhs) const
@mcg1969
mcg1969 / octave-configure.diff
Created January 9, 2014 02:20
Patches Octave 3.8.0's configure script so that it can find the QT framework when installed via Homebrew.
diff --git a/configure b/configure
index 96ab21c..662d720 100755
--- a/configure
+++ b/configure
@@ -68538,8 +68538,8 @@ fi
if test $build_gui = yes; then
## Retrieve Qt compilation and linker flags
QT_CPPFLAGS="`$PKG_CONFIG --cflags-only-I QtCore QtGui QtNetwork`"
- QT_LDFLAGS="`$PKG_CONFIG --libs-only-L QtCore QtGui QtNetwork`"
- QT_LIBS="`$PKG_CONFIG --libs-only-l QtCore QtGui QtNetwork`"
@mcg1969
mcg1969 / octave-libtool.diff
Last active January 2, 2016 16:09
Patches Octave 3.8.0's libtool script to properly recognize -F framework location flags. Intended for use with Homebrew.
diff --git a/build-aux/ltmain.sh b/build-aux/ltmain.sh
index 68c6d96..d3c3847 100644
--- a/build-aux/ltmain.sh
+++ b/build-aux/ltmain.sh
@@ -5546,13 +5546,17 @@ func_mode_link ()
continue
;;
- -L*)
- func_stripname "-L" '' "$arg"
@mcg1969
mcg1969 / keybase.md
Created May 6, 2016 13:28
Keybase prooftext

Keybase proof

I hereby claim:

  • I am mcg1969 on github.
  • I am mcg (https://keybase.io/mcg) on keybase.
  • I have a public key whose fingerprint is 63CF 4B6F 0482 5A8F ECFE 55A1 578A 73BA 22AE EDE0

To claim this, I am signing this object:

DEBUG:conda.config:Could not import binstar
DEBUG:conda.fetch:channel_urls=('https://repo.continuum.io/pkgs/free/win-64/', 'https://repo.continuum.io/pkgs/free/noarch/', 'https://repo.continuum.io/pkgs/pro/win-64/', 'https://repo.continuum.io/pkgs/pro/noarch/', 'https://conda.anaconda.org/blaze/win-64/', 'https://conda.anaconda.org/blaze/noarch/')
Fetching package metadata: INFO:stdoutlog:Fetching package metadata:
DEBUG:requests.packages.urllib3.util.retry:Converted retries value: 3 -> Retry(total=3, connect=None, read=None, redirect=None)
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (1): repo.continuum.io
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (1): conda.anaconda.org
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (2): repo.continuum.io
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (2): conda.anaconda.org
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (3
DEBUG:conda.config:Could not import binstar
DEBUG:conda.fetch:channel_urls=OrderedDict([('https://repo.continuum.io/pkgs/free/win-64/', ('defaults', 1)), ('https://repo.continuum.io/pkgs/free/noarch/', ('defaults', 1)), ('https://repo.continuum.io/pkgs/pro/win-64/', ('defaults', 1)), ('https://repo.continuum.io/pkgs/pro/noarch/', ('defaults', 1)), ('https://conda.anaconda.org/blaze/win-64/', ('blaze', 2)), ('https://conda.anaconda.org/blaze/noarch/', ('blaze', 2))])
Fetching package metadata ...INFO:stdoutlog:Fetching package metadata ...
DEBUG:requests.packages.urllib3.util.retry:Converted retries value: 3 -> Retry(total=3, connect=None, read=None, redirect=None)
DEBUG:requests.packages.urllib3.util.retry:Converted retries value: 3 -> Retry(total=3, connect=None, read=None, redirect=None)
DEBUG:requests.packages.urllib3.util.retry:Converted retries value: 3 -> Retry(total=3, connect=None, read=None, redirect=None)
DEBUG:requests.packages.urllib3.util.retry:Converted retries value: 3 -> Retry(total=3, connect
DEBUG:conda.config:Could not import binstar
DEBUG:conda.fetch:channel_urls=('https://repo.continuum.io/pkgs/free/win-64/', 'https://repo.continuum.io/pkgs/free/noarch/', 'https://repo.continuum.io/pkgs/pro/win-64/', 'https://repo.continuum.io/pkgs/pro/noarch/', 'https://conda.anaconda.org/blaze/win-64/', 'https://conda.anaconda.org/blaze/noarch/')
Fetching package metadata: INFO:stdoutlog:Fetching package metadata:
DEBUG:requests.packages.urllib3.util.retry:Converted retries value: 3 -> Retry(total=3, connect=None, read=None, redirect=None)
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (1): conda.anaconda.org
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (2): conda.anaconda.org
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (1): repo.continuum.io
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (2): repo.continuum.io
INFO:requests.packages.urllib3.connectionpool:Starting new HTTPS connection (3
@mcg1969
mcg1969 / variants.md
Last active December 12, 2017 14:57
Conda hackery: variants

Conda proposal: variants

Motivation

There are many situations where we are inclined to produce multiple variants of the same package, with each variant depending on a different set of low-level dependencies. For instance: