2011-03-10 05:11:03 +00:00
|
|
|
class Devil < Formula
|
2015-05-19 00:00:59 +00:00
|
|
|
desc "Cross-platform image library"
|
2015-11-12 02:36:09 +00:00
|
|
|
homepage "https://sourceforge.net/projects/openil/"
|
2015-08-03 12:55:31 +00:00
|
|
|
url "https://downloads.sourceforge.net/project/openil/DevIL/1.7.8/DevIL-1.7.8.tar.gz"
|
|
|
|
sha256 "682ffa3fc894686156337b8ce473c954bf3f4fb0f3ecac159c73db632d28a8fd"
|
2014-03-23 02:51:41 +00:00
|
|
|
revision 1
|
2010-10-07 03:14:58 +00:00
|
|
|
|
2015-11-15 16:26:23 +00:00
|
|
|
bottle :disable, "Can't generate bottles until builds with either Clang or GCC-5"
|
|
|
|
|
2015-12-19 06:59:33 +00:00
|
|
|
option :universal
|
|
|
|
|
2015-08-03 12:55:31 +00:00
|
|
|
depends_on "libpng"
|
|
|
|
depends_on "jpeg"
|
2010-09-26 18:31:41 +00:00
|
|
|
|
2015-11-12 02:36:09 +00:00
|
|
|
# see https://sourceforge.net/p/openil/bugs/204/
|
2012-05-21 23:03:34 +00:00
|
|
|
# also, even with -std=gnu99 removed from the configure script,
|
|
|
|
# devil fails to build with clang++ while compiling il_exr.cpp
|
|
|
|
fails_with :clang do
|
|
|
|
cause "invalid -std=gnu99 flag while building C++"
|
|
|
|
end
|
|
|
|
|
2015-06-09 17:43:29 +00:00
|
|
|
# ./../src-IL/include/il_internal.h:230:54: error: expected ',' or '...' before 'FileName'
|
|
|
|
# https://github.com/Homebrew/homebrew/issues/40442
|
|
|
|
fails_with :gcc => "5"
|
|
|
|
|
2010-10-07 03:14:58 +00:00
|
|
|
# fix compilation issue for iluc.c
|
2014-03-18 17:13:31 +00:00
|
|
|
patch :DATA
|
2009-10-18 19:05:19 +00:00
|
|
|
|
|
|
|
def install
|
2014-01-17 20:59:54 +00:00
|
|
|
ENV.universal_binary if build.universal?
|
|
|
|
|
2012-06-07 22:39:35 +00:00
|
|
|
system "./configure", "--disable-debug",
|
|
|
|
"--disable-dependency-tracking",
|
|
|
|
"--prefix=#{prefix}",
|
|
|
|
"--enable-ILU",
|
|
|
|
"--enable-ILUT"
|
2015-08-03 12:55:31 +00:00
|
|
|
system "make", "install"
|
2009-10-18 19:05:19 +00:00
|
|
|
end
|
|
|
|
end
|
2010-10-07 03:14:58 +00:00
|
|
|
|
2010-09-26 18:31:41 +00:00
|
|
|
__END__
|
|
|
|
--- a/src-ILU/ilur/ilur.c 2009-03-08 08:10:12.000000000 +0100
|
|
|
|
+++ b/src-ILU/ilur/ilur.c 2010-09-26 20:01:45.000000000 +0200
|
|
|
|
@@ -1,6 +1,7 @@
|
|
|
|
#include <string.h>
|
|
|
|
#include <stdio.h>
|
|
|
|
-#include <malloc.h>
|
|
|
|
+#include <stdlib.h>
|
|
|
|
+#include "sys/malloc.h"
|
|
|
|
|
|
|
|
#include <IL/il.h>
|
|
|
|
#include <IL/ilu.h>
|
|
|
|
|