Skip to content

Instantly share code, notes, and snippets.

@d235j
d235j / bdw-gc.rb.diff
Last active June 4, 2018 22:04
addition to bdw-gc for handle-fork
diff --git a/Formula/bdw-gc.rb b/Formula/bdw-gc.rb
index 794838f2f..ac3bbddcd 100644
--- a/Formula/bdw-gc.rb
+++ b/Formula/bdw-gc.rb
@@ -11,6 +11,8 @@ class BdwGc < Formula
sha256 "13cd1da271d203af0e834a53f232122ab0a740bf9bbb68c68cc172bd23654eab" => :el_capitan
end
+ option "with-handle-fork", "Enable handle fork functionality"
+
head do
Compiling [1 of 54] #P"/sources/cl/clasp/src/lisp/kernel/tag/min-start.lsp"
to #P"/sources/cl/clasp/build/boehm/fasl/aclasp-boehm-bitcode/src/lisp/kernel/tag/min-start.ll" - will reload: T
../../src/core/exceptions.cc:151 core__signal_simple_error caught because signal-simple-error is not installed yet
../../src/core/exceptions.cc:152 baseCondition: SIMPLE-PROGRAM-ERROR
../../src/core/exceptions.cc:153 formatControl: Too few arguments given 12 required 13
../../src/core/exceptions.cc:154 formatArgs: NIL
../../src/core/exceptions.cc:159 About to try and FORMAT the error
Too few arguments given 12 required 13
core__signal_simple_error
@d235j
d235j / InfoIC_modified_671.c
Created April 28, 2018 21:03
tl866 InfoIC extractor
// InfoIC.dll extractor from http://www.nullsecurity.org/i/showoff/parse_InfoIC.c
// Modified to be POSIX C and to work with v6.7.1 of the software
// TL866II Plus DLL has a slightly different structure
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <string.h>
@d235j
d235j / makerbot_rep2x_1st.def.json
Created November 26, 2017 22:52
Replicator 2X Cura definition
{
"id": "makerbot_rep2x_1st",
"version": 2,
"name": "1st Extruder",
"inherits": "fdmextruder",
"metadata": {
"machine": "makerbot_replicator_2x",
"position": "0"
},
--- tools/linguist/linguist/messagemodel.cpp.orig 2017-08-01 11:27:59.000000000 -0400
+++ tools/linguist/linguist/messagemodel.cpp 2017-08-01 11:28:09.000000000 -0400
@@ -183,7 +183,7 @@
if (ContextItem *c = one->findContext(oc->context())) {
for (int j = 0; j < oc->messageCount(); ++j) {
MessageItem *m = oc->messageItem(j);
- if (c->findMessage(m->text(), m->comment()) >= 0)
+ if (c->findMessage(m->text(), m->comment()) != NULL)
++inBoth;
}
--- src/gui/kernel/qt_cocoa_helpers_mac.mm.orig 2017-08-01 09:43:40.000000000 -0400
+++ src/gui/kernel/qt_cocoa_helpers_mac.mm 2017-08-01 09:47:33.000000000 -0400
@@ -73,6 +73,9 @@
**
****************************************************************************/
+// Workaround for macOS 10.13 and later
+#define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 1
+
#include <private/qcore_mac_p.h>
@d235j
d235j / r2ida.py
Created July 12, 2016 04:49
Script to convert radare2 annotations to IDC format
#!/usr/bin/env python
from __future__ import print_function
import argparse
import json
import sys
# Parse r2 scripts into IDA IDC format
# This only handles a few commands but is good enough for our uses.
# Works with Python 2 and 3
=== modified file '3d-viewer/3d_canvas.cpp'
--- 3d-viewer/3d_canvas.cpp 2016-01-25 00:18:29 +0000
+++ 3d-viewer/3d_canvas.cpp 2016-01-25 18:29:20 +0000
@@ -284,19 +284,18 @@
void EDA_3D_CANVAS::OnMouseWheel( wxMouseEvent& event )
{
- if( event.ShiftDown() )
+ double delta = 0.05 * GetPrm3DVisu().m_Zoom * event.GetWheelRotation();
+
@d235j
d235j / cmake-skip-archcheck.diff
Created November 5, 2015 21:20
Skip CMake arch check on Mac OS X
diff --git a/Modules/BasicConfigVersion-AnyNewerVersion.cmake.in b/Modules/BasicConfigVersion-AnyNewerVersion.cmake.in
index bc78016..2e64771 100644
--- a/Modules/BasicConfigVersion-AnyNewerVersion.cmake.in
+++ b/Modules/BasicConfigVersion-AnyNewerVersion.cmake.in
@@ -18,6 +18,12 @@ else()
endif()
endif()
+
+# if on an Apple platform, this project might have been built as a universal binary, in which case CMAKE_SIZEOF_VOID_P will be incorrect:
@d235j
d235j / cmake-patch-Modules-noArchCheck.3.3.diff
Created November 5, 2015 05:05
Remove CMake arch check (patch from MacPorts)
--- Modules/BasicConfigVersion-AnyNewerVersion.cmake.in.orig
+++ Modules/BasicConfigVersion-AnyNewerVersion.cmake.in
@@ -17,15 +17,3 @@
set(PACKAGE_VERSION_EXACT TRUE)
endif()
endif()
-
-# if the installed or the using project don't have CMAKE_SIZEOF_VOID_P set, ignore it:
-if("${CMAKE_SIZEOF_VOID_P}" STREQUAL "" OR "@CMAKE_SIZEOF_VOID_P@" STREQUAL "")
- return()