graphics/devil: Fix build with jasper 3.0.2
Approved by: portmgr (blanket)
This commit is contained in:
parent
87cebeb7a9
commit
7f9a658424
1 changed files with 13 additions and 4 deletions
|
@ -1,18 +1,27 @@
|
|||
--- DevIL/src-IL/src/il_jp2.cpp.orig 2017-01-01 23:37:37 UTC
|
||||
+++ DevIL/src-IL/src/il_jp2.cpp
|
||||
@@ -314,13 +314,13 @@ ILboolean iLoadJp2Internal(jas_stream_t *Stream, ILima
|
||||
|
||||
@@ -313,14 +313,21 @@ ILboolean iLoadJp2Internal(jas_stream_t *Stream, ILima
|
||||
}
|
||||
|
||||
|
||||
-
|
||||
-static int iJp2_file_read(jas_stream_obj_t *obj, char *buf, int cnt)
|
||||
+static int iJp2_file_read(jas_stream_obj_t *obj, char *buf, unsigned int cnt)
|
||||
+#if JAS_VERSION_MAJOR >= 3
|
||||
+static ssize_t iJp2_file_read(jas_stream_obj_t *obj, char *buf, size_t cnt)
|
||||
+#else
|
||||
+static int iJp2_file_read(jas_stream_obj_t *obj, char *buf, unsigned long cnt)
|
||||
+#endif
|
||||
{
|
||||
obj;
|
||||
return iread(buf, 1, cnt);
|
||||
}
|
||||
|
||||
-static int iJp2_file_write(jas_stream_obj_t *obj, char *buf, int cnt)
|
||||
+static int iJp2_file_write(jas_stream_obj_t *obj, const char *buf, unsigned int cnt)
|
||||
+#if JAS_VERSION_MAJOR >= 3
|
||||
+static ssize_t iJp2_file_write(jas_stream_obj_t *obj, const char *buf, size_t cnt)
|
||||
+#else
|
||||
+static int iJp2_file_write(jas_stream_obj_t *obj, const char *buf, unsigned long cnt)
|
||||
+#endif
|
||||
{
|
||||
obj;
|
||||
return iwrite(buf, 1, cnt);
|
||||
|
|
Loading…
Reference in a new issue