Skip to content

Instantly share code, notes, and snippets.

@2bits
2bits / ltmain.sh.patch
Created September 28, 2011 20:22
flac-1.2.1/ltmain.sh patch for Mac OS to disable libtool relink, from Macports and/or Fink
--- ltmain.sh.orig Fri Feb 4 21:22:19 2005
+++ ltmain.sh Wed Feb 23 19:09:37 2005
@@ -2280,7 +2280,7 @@
{ test "$prefer_static_libs" = no || test -z "$old_library"; }; then
if test "$installed" = no; then
notinst_deplibs="$notinst_deplibs $lib"
- need_relink=yes
+ need_relink=no
fi
# This is a shared library
@2bits
2bits / lib.mk.patch
Created September 28, 2011 20:36
flac-1.2.1/build/lib.mk patch for Mac OS ld to mark undefined symbols for dynamic_lookup, from Macports and/or Fink
--- build/lib.mk.orig 2007-09-13 10:51:25.000000000 +1000
+++ build/lib.mk 2009-02-10 08:27:43.000000000 +1100
@@ -51,7 +51,7 @@
RELEASE_STATIC_LIB = $(RELEASE_LIBPATH)/$(STATIC_LIB_NAME)
RELEASE_DYNAMIC_LIB = $(RELEASE_LIBPATH)/$(DYNAMIC_LIB_NAME)
ifeq ($(DARWIN_BUILD),yes)
-LINKD = $(CC) -dynamiclib -flat_namespace -undefined suppress -install_name $(DYNAMIC_LIB)
+LINKD = $(CC) -dynamiclib -undefined dynamic_lookup -install_name $(DYNAMIC_LIB)
else
LINKD = $(CC) -shared
@2bits
2bits / nasm.h.patch
Created September 28, 2011 20:45
flac-1.2.1/src/libFLAC/ia32/nasm.h Patchfile to support i386 Mac OSX style macho asm section headers, from Macports/Fink
--- src/libFLAC/ia32/nasm.h~ 2005-01-25 13:14:22.000000000 +0900
+++ src/libFLAC/ia32/nasm.h 2006-03-15 18:07:23.000000000 +0900
@@ -49,6 +49,11 @@
%idefine code_section section .text align=16
%idefine data_section section .data align=32
%idefine bss_section section .bss align=32
+%elifdef OBJ_FORMAT_macho
+ %define FLAC__PUBLIC_NEEDS_UNDERSCORE
+ %idefine code_section section .text
+ %idefine data_section section .data
@2bits
2bits / config.h.patch
Created September 28, 2011 21:17
flac-1.2.1/config.h Patch for 32 vs 64 SIZEOF_VOIDP on Mac OSX universal builds, from Macports/Fink
diff --git a/config.h b/config.h
index 4ea0e2c..27fcf18 100644
--- a/config.h
+++ b/config.h
@@ -113,7 +113,11 @@
#define PACKAGE_VERSION ""
/* The size of a `void*', as computed by sizeof. */
+#ifdef __LP64__
#define SIZEOF_VOIDP 8
@2bits
2bits / fixrpath.sh
Created September 28, 2011 22:47
flac-1.2.1 Shell script modifies libtool doing -rpath workaround for hardwiring locations
--- fixrpath.sh 1969-12-31 19:00:00.000000000 -0500
+++ fixrpath.sh 2008-02-18 10:51:07.000000000 -0500
@@ -0,0 +1,28 @@
+#!/bin/sh
+# $Id: fixrpath,v 1.1 2004/05/27 10:48:25 kobras Exp $
+# libtool -rpath workaround based on a suggestion by Yann Dirson
+# <dirson <at> debian.org>
+#
+# It is supposed to be inserted in configure.in, but I didn't want
+# to re-run autoconf (since that bloats the Debian diff unnecessarily),
@2bits
2bits / bitreader_asm.nasm.patch
Created September 30, 2011 06:04
flac-1.2.1/src/libFLAC/ia32/bitreader_asm.nasm Fixes illegal text reloc for elf in asm code, from Richard Ash Audacity
Doesn't work yet for macho
--- src/libFLAC/ia32/bitreader_asm.nasm.orig 2007-03-29 17:54:53.000000000 -0700
+++ src/libFLAC/ia32/bitreader_asm.nasm 2011-09-29 23:51:01.000000000 -0700
@@ -138,10 +138,20 @@
mov ecx, [ebp + 28] ; ecx <- br->crc16_align
mov eax, [ebp + 24] ; ax <- br->read_crc (a.k.a. crc)
%ifdef FLAC__PUBLIC_NEEDS_UNDERSCORE
+%ifdef OBJ_FORMAT_macho
@2bits
2bits / configure.opt.txt
Created October 6, 2011 00:23
A configure option from ncurses-5.9
--disable-overwrite
If you are installing ncurses on a system which contains another
development version of curses, or which could be confused by the loader
for another version, we recommend that you leave out the link to
-lcurses. The ncurses library is always available as -lncurses.
Disabling overwrite also causes the ncurses header files to be
installed into a subdirectory, e.g., /usr/local/include/ncurses,
rather than the include directory. This makes it simpler to avoid
compile-time conflicts with other versions of curses.h
@2bits
2bits / admcli.txt
Created October 17, 2011 22:07
avidemux2_cli --help ==> from svn 2.5 grunster on OSX x86_64 Snow Leopar2d
*************************
Avidemux v2.5.5
*************************
http://www.avidemux.org
Code : Mean, JSC, Grant Pedersen
GFX : Nestor Di, [email protected]
Design : Jakub Misak
FreeBSD : Anish Mistry, [email protected]
Audio : Mihail Zenkov
Mac OS X : Kuisathaverat, Harry van der Wolf
@2bits
2bits / admqt4.txt
Created October 17, 2011 22:21
avidemux2_qt4 console log <= using svn 2.5 grunster on OSX x86_64 Snow Leopard
10/17/11 3:17:18 PM *************************
10/17/11 3:17:18 PM Avidemux v2.5.5
10/17/11 3:17:18 PM *************************
10/17/11 3:17:18 PM http://www.avidemux.org
10/17/11 3:17:18 PM Code : Mean, JSC, Grant Pedersen
10/17/11 3:17:18 PM GFX : Nestor Di, [email protected]
10/17/11 3:17:18 PM Design : Jakub Misak
10/17/11 3:17:18 PM FreeBSD : Anish Mistry, [email protected]
10/17/11 3:17:18 PM Audio : Mihail Zenkov
10/17/11 3:17:18 PM Mac OS X : Kuisathaverat, Harry van der Wolf
@2bits
2bits / make.macbuild.txt
Created October 18, 2011 03:38
avidemux-2.5 svn grunster output from make in macbuild on OSX Snow Leopard showing libADM_coreAudio.dylib built
/usr/local/Cellar/cmake/2.8.6/bin/cmake -H/tmp/topp -B/tmp/topp/macbuild --check-build-system CMakeFiles/Makefile.cmake 0
/usr/local/Cellar/cmake/2.8.6/bin/cmake -E cmake_progress_start /tmp/topp/macbuild/CMakeFiles /tmp/topp/macbuild/CMakeFiles/progress.marks
make -f CMakeFiles/Makefile2 all
make -f avidemux/ADM_core/src/CMakeFiles/ADM_core.dir/build.make avidemux/ADM_core/src/CMakeFiles/ADM_core.dir/depend
cd /tmp/topp/macbuild && /usr/local/Cellar/cmake/2.8.6/bin/cmake -E cmake_depends "Unix Makefiles" /tmp/topp /tmp/topp/avidemux/ADM_core/src /tmp/topp/macbuild /tmp/topp/macbuild/avidemux/ADM_core/src /tmp/topp/macbuild/avidemux/ADM_core/src/CMakeFiles/ADM_core.dir/DependInfo.cmake --color=
Scanning dependencies of target ADM_core
make -f avidemux/ADM_core/src/CMakeFiles/ADM_core.dir/build.make avidemux/ADM_core/src/CMakeFiles/ADM_core.dir/build
/usr/local/Cellar/cmake/2.8.6/bin/cmake -E cmake_progress_report /tmp/topp/macbuild/CMakeFiles
[ 0%] Building CXX object avidemux/ADM_core/src/CMakeFiles/ADM_core