Created
February 14, 2012 06:25
-
-
Save tnoda/1824249 to your computer and use it in GitHub Desktop.
A homebrew formula for cmigemo on Mac OS X 10.6.8
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class Cmigemo < Formula | |
url 'http://cmigemo.googlecode.com/files/cmigemo-default-src-20110227.zip' | |
homepage 'http://www.kaoriya.net/software/cmigemo' | |
sha1 '25e279c56d3a8f1e82cbfb3526d1b38742d1d66c' | |
depends_on 'nkf' | |
def patches | |
DATA | |
end | |
def install | |
File.chmod(0755, "./configure") | |
system "./configure", "--prefix=#{prefix}" | |
system "make osx" | |
system "make osx-dict" | |
Dir.chdir 'dict' do | |
system "make utf-8" | |
end | |
mkdir "#{prefix}/lib" | |
mkdir "#{prefix}/share" | |
mkdir "#{prefix}/share/migemo" | |
mkdir "#{prefix}/share/migemo/cp932" | |
mkdir "#{prefix}/share/migemo/euc-jp" | |
mkdir "#{prefix}/share/migemo/utf-8" | |
system "make osx-install" | |
system "install_name_tool -change libmigemo.1.dylib #{prefix}/lib/libmigemo.1.dylib #{prefix}/bin/cmigemo" | |
end | |
end | |
__END__ | |
--- a/src/wordbuf.c 2011-07-29 13:05:12.000000000 +0900 | |
+++ b/src/wordbuf.c 2011-07-29 13:04:28.000000000 +0900 | |
@@ -9,6 +9,7 @@ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
+#include <limits.h> | |
#include "wordbuf.h" | |
#define WORDLEN_DEF 64 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The original version has been gisted at https://gist.github.com/1116133.