summaryrefslogtreecommitdiff
path: root/homebrew/crystal
diff options
context:
space:
mode:
Diffstat (limited to 'homebrew/crystal')
-rw-r--r--homebrew/crystal/.beer78
-rw-r--r--homebrew/crystal/.make.sh-auto11
-rw-r--r--homebrew/crystal/_metadata/description1
-rw-r--r--homebrew/crystal/_metadata/homepage1
-rw-r--r--homebrew/crystal/_metadata/name1
-rw-r--r--homebrew/crystal/_metadata/version1
-rwxr-xr-xhomebrew/crystal/download.sh1
7 files changed, 94 insertions, 0 deletions
diff --git a/homebrew/crystal/.beer b/homebrew/crystal/.beer
new file mode 100644
index 000000000..3ff16414a
--- /dev/null
+++ b/homebrew/crystal/.beer
@@ -0,0 +1,78 @@
+{
+ "name": "Crystal",
+ "description": "Fast and statically typed, compiled language with Ruby-like syntax",
+ "url": "https://github.com/crystal-lang/crystal/archive/0.27.2.tar.gz",
+ "mirror": null,
+ "homepage": "https://crystal-lang.org/",
+ "depends": [
+ {
+ "depend": "libatomic_ops",
+ "build-depend": false
+ },
+ {
+ "depend": "bdw-gc",
+ "build-depend": false
+ },
+ {
+ "depend": "gmp",
+ "build-depend": false
+ },
+ {
+ "depend": "libevent",
+ "build-depend": false
+ },
+ {
+ "depend": "libyaml",
+ "build-depend": false
+ },
+ {
+ "depend": "llvm@6",
+ "build-depend": false
+ },
+ {
+ "depend": "pcre",
+ "build-depend": false
+ },
+ {
+ "depend": "pkg-config",
+ "build-depend": false
+ }
+ ],
+ "resource": [
+ {
+ "name": "shards",
+ "url": "https://github.com/crystal-lang/shards/archive/v0.8.1.tar.gz"
+ },
+ {
+ "name": "shards",
+ "url": "https://github.com/crystal-lang/shards.git"
+ },
+ {
+ "name": "boot",
+ "url": "https://github.com/crystal-lang/crystal/releases/download/0.27.1/crystal-0.27.1-1-darwin-x86_64.tar.gz"
+ }
+ ],
+ "conflicts": [],
+ "patches": [],
+ "install": [
+ "(buildpath/\"boot\").install resource(\"boot\")",
+ "if build.head?",
+ "ENV[\"CRYSTAL_CONFIG_BUILD_COMMIT\"] = Utils.popen_read(\"git rev-parse --short HEAD\").strip",
+ "end",
+ "ENV[\"CRYSTAL_CONFIG_PATH\"] = prefix/\"src:lib\"",
+ "ENV.append_path \"PATH\", \"boot/bin\"",
+ "system \"make\", \"deps\"",
+ "(buildpath/\".build\").mkpath",
+ "system \"bin/crystal\", \"build\",",
+ "\"-D\", \"without_openssl\",",
+ "\"-D\", \"without_zlib\",",
+ "\"-D\", \"preview_overflow\",",
+ "\"-o\", \".build/crystal\",",
+ "\"src/compiler/crystal.cr\",",
+ "\"--release\", \"--no-debug\"",
+ "resource(\"shards\").stage do",
+ "system buildpath/\"bin/crystal\", \"build\", \"-o\", buildpath/\".build/shards\", \"src/shards.cr\""
+ ],
+ "version": "0.27.2",
+ "file": "crystal.rb"
+} \ No newline at end of file
diff --git a/homebrew/crystal/.make.sh-auto b/homebrew/crystal/.make.sh-auto
new file mode 100644
index 000000000..21132a878
--- /dev/null
+++ b/homebrew/crystal/.make.sh-auto
@@ -0,0 +1,11 @@
+pkg:setup
+(buildpath/"boot").install resource("boot")
+ENV["CRYSTAL_CONFIG_BUILD_COMMIT"] = Utils.popen_read("git rev-parse --short HEAD").strip
+end
+ENV["CRYSTAL_CONFIG_PATH"] = prefix/"src:lib"
+ENV.append_path "PATH", "boot/bin"
+make deps
+(buildpath/".build").mkpath
+bin/crystal build -D without_openssl -D without_zlib -D preview_overflow -o .build/crystal src/compiler/crystal.cr --release --no-debug
+resource("shards").stage do
+buildpath/"bin/crystal" build -o buildpath/".build/shards" src/shards.cr
diff --git a/homebrew/crystal/_metadata/description b/homebrew/crystal/_metadata/description
new file mode 100644
index 000000000..93c1bc18b
--- /dev/null
+++ b/homebrew/crystal/_metadata/description
@@ -0,0 +1 @@
+Fast and statically typed, compiled language with Ruby-like syntax
diff --git a/homebrew/crystal/_metadata/homepage b/homebrew/crystal/_metadata/homepage
new file mode 100644
index 000000000..a34d1f5b9
--- /dev/null
+++ b/homebrew/crystal/_metadata/homepage
@@ -0,0 +1 @@
+https://crystal-lang.org/
diff --git a/homebrew/crystal/_metadata/name b/homebrew/crystal/_metadata/name
new file mode 100644
index 000000000..51a8ec8df
--- /dev/null
+++ b/homebrew/crystal/_metadata/name
@@ -0,0 +1 @@
+Crystal
diff --git a/homebrew/crystal/_metadata/version b/homebrew/crystal/_metadata/version
new file mode 100644
index 000000000..3edc695dc
--- /dev/null
+++ b/homebrew/crystal/_metadata/version
@@ -0,0 +1 @@
+0.27.2
diff --git a/homebrew/crystal/download.sh b/homebrew/crystal/download.sh
new file mode 100755
index 000000000..1de4bf27d
--- /dev/null
+++ b/homebrew/crystal/download.sh
@@ -0,0 +1 @@
+wget https://github.com/crystal-lang/crystal/archive/0.27.2.tar.gz \ No newline at end of file