devel/libzim: update to 4.0.0

This commit is contained in:
Steve Wills 2018-07-11 11:42:29 +00:00
parent 2f9d28d8cf
commit 9a69da7dbd
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=474436
8 changed files with 73 additions and 21 deletions

View file

@ -1,19 +1,22 @@
# $FreeBSD$
PORTNAME= libzim
PORTVERSION= 2.0.0
PORTREVISION= 2
PORTVERSION= 4.0.0
CATEGORIES= devel
MAINTAINER= swills@FreeBSD.org
COMMENT= Reference implementation of the ZIM specification
BUILD_DEPENDS= python3-config:lang/python3
LIB_DEPENDS= libicui18n.so:devel/icu \
libxapian.so:databases/xapian-core
USES= meson pkgconfig
USES= compiler:c++11-lang meson pkgconfig python:3.4+
USE_LDCONFIG= yes
USE_GITHUB= yes
GH_ACCOUNT= openzim
# Using gcc6 and libstdc++ leads to error because xapian-core is linked with libc++
BROKEN_FreeBSD_10= /usr/include/c++/v1/memory:4004:35: error: no viable overloaded '='
.include <bsd.port.mk>

View file

@ -1,3 +1,3 @@
TIMESTAMP = 1505422546
SHA256 (openzim-libzim-2.0.0_GH0.tar.gz) = c148aa62a346628447093b0b1eb0b2f1a7236c7555ed2bdd74515b0cc75b167c
SIZE (openzim-libzim-2.0.0_GH0.tar.gz) = 86835
TIMESTAMP = 1531269487
SHA256 (openzim-libzim-4.0.0_GH0.tar.gz) = e195d30ba1b55dd2b6529fdd84fcbed6ec35ed4ddc957ad7725edabd20c3126c
SIZE (openzim-libzim-4.0.0_GH0.tar.gz) = 1649903

View file

@ -0,0 +1,17 @@
--- meson.build.orig 2018-07-11 01:42:53.056789000 +0000
+++ meson.build 2018-07-11 01:42:55.616640000 +0000
@@ -9,6 +9,9 @@ conf.set('DIRENT_CACHE_SIZE', get_option('DIRENT_CACHE
conf.set('CLUSTER_CACHE_SIZE', get_option('CLUSTER_CACHE_SIZE'))
conf.set('LZMA_MEMORY_SIZE', get_option('LZMA_MEMORY_SIZE'))
+cc = meson.get_compiler('c')
+execinfo_dep = cc.find_library('execinfo', required : false)
+
zlib_dep = dependency('zlib', required:false)
conf.set('ENABLE_ZLIB', zlib_dep.found())
@@ -49,3 +52,4 @@ pkg_mod.generate(libraries : libzim,
filebase : 'libzim',
description : 'A Library to zim.',
requires : pkg_requires)
+

View file

@ -0,0 +1,11 @@
--- src/buffer.cpp.orig 2018-07-11 01:24:59.809896000 +0000
+++ src/buffer.cpp 2018-07-11 01:25:29.007975000 +0000
@@ -48,7 +48,7 @@ MMapBuffer::MMapBuffer(int fd, offset_t offset, zsize_
#if defined(__APPLE__)
#define MAP_FLAGS MAP_PRIVATE
#else
- #define MAP_FLAGS MAP_PRIVATE|MAP_POPULATE
+ #define MAP_FLAGS MAP_PRIVATE|MAP_PREFAULT_READ
#endif
_data = (char*)mmap(NULL, size.v + _offset.v, PROT_READ, MAP_FLAGS, fd, pa_offset.v);
if (_data == MAP_FAILED )

View file

@ -0,0 +1,10 @@
--- src/file_compound.h.orig 2018-07-11 01:26:16.144860000 +0000
+++ src/file_compound.h 2018-07-11 01:26:30.132058000 +0000
@@ -25,6 +25,7 @@
#include <map>
#include <memory>
#include <cstdio>
+#include <time.h>
namespace zim {

View file

@ -0,0 +1,10 @@
--- src/file_reader.cpp.orig 2018-07-11 01:18:06.970719000 +0000
+++ src/file_reader.cpp 2018-07-11 01:18:17.646078000 +0000
@@ -28,6 +28,7 @@
#include <fcntl.h>
#include <lzma.h>
#include <pthread.h>
+#include <unistd.h>
#if defined(ENABLE_ZLIB)
#include <zlib.h>

View file

@ -0,0 +1,13 @@
--- src/meson.build.orig 2018-07-11 01:43:01.888587000 +0000
+++ src/meson.build 2018-07-11 01:43:07.416631000 +0000
@@ -51,6 +51,10 @@ if zlib_dep.found()
deps += [zlib_dep]
endif
+if execinfo_dep.found()
+ deps += [execinfo_dep]
+endif
+
if xapian_dep.found()
sources += xapian_sources
sources += lib_resources

View file

@ -1,28 +1,16 @@
bin/zimdump
bin/zimsearch
include/zim/article.h
include/zim/blob.h
include/zim/cache.h
include/zim/cluster.h
include/zim/dirent.h
include/zim/error.h
include/zim/file.h
include/zim/fileheader.h
include/zim/fileimpl.h
include/zim/fileiterator.h
include/zim/fstream.h
include/zim/noncopyable.h
include/zim/refcounted.h
include/zim/search.h
include/zim/search_iterator.h
include/zim/smartptr.h
include/zim/template.h
include/zim/uuid.h
include/zim/writer/articlesource.h
include/zim/writer/dirent.h
include/zim/writer/article.h
include/zim/writer/zimcreator.h
include/zim/zim.h
lib/libzim.so
lib/libzim.so.2
lib/libzim.so.2.0.0
lib/libzim.so.4
lib/libzim.so.4.0.0
libdata/pkgconfig/libzim.pc