From owner-svn-ports-head@freebsd.org Sun Jan 5 04:05:31 2020 Return-Path: Delivered-To: svn-ports-head@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id CF5201D76A5; Sun, 5 Jan 2020 04:05:31 +0000 (UTC) (envelope-from sunpoet@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 47r4mp74KDz3Jfy; Sun, 5 Jan 2020 04:05:30 +0000 (UTC) (envelope-from sunpoet@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id D8CC61FC9A; Sun, 5 Jan 2020 04:05:30 +0000 (UTC) (envelope-from sunpoet@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 00545Uu5047287; Sun, 5 Jan 2020 04:05:30 GMT (envelope-from sunpoet@FreeBSD.org) Received: (from sunpoet@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 00545Txc047281; Sun, 5 Jan 2020 04:05:29 GMT (envelope-from sunpoet@FreeBSD.org) Message-Id: <202001050405.00545Txc047281@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sunpoet set sender to sunpoet@FreeBSD.org using -f From: Sunpoet Po-Chuan Hsieh Date: Sun, 5 Jan 2020 04:05:29 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r522082 - in head/x11-fonts: . ots ots/files X-SVN-Group: ports-head X-SVN-Commit-Author: sunpoet X-SVN-Commit-Paths: in head/x11-fonts: . ots ots/files X-SVN-Commit-Revision: 522082 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 05 Jan 2020 04:05:32 -0000 Author: sunpoet Date: Sun Jan 5 04:05:28 2020 New Revision: 522082 URL: https://svnweb.freebsd.org/changeset/ports/522082 Log: Add ots 8.0.0 The OpenType Sanitizer (OTS) parses and serializes OpenType files (OTF, TTF) and WOFF and WOFF2 font files, validating them and sanitizing them as it goes. The C library is integrated into Chromium and Firefox, and also simple command line tools to check files offline in a Terminal. The CSS font-face property is great for web typography. Having to use images in order to get the correct typeface is a great sadness; one should be able to use vectors. WWW: https://github.com/khaledhosny/ots Added: head/x11-fonts/ots/ head/x11-fonts/ots/Makefile (contents, props changed) head/x11-fonts/ots/distinfo (contents, props changed) head/x11-fonts/ots/files/ head/x11-fonts/ots/files/patch-meson.build (contents, props changed) head/x11-fonts/ots/pkg-descr (contents, props changed) head/x11-fonts/ots/pkg-plist (contents, props changed) Modified: head/x11-fonts/Makefile Modified: head/x11-fonts/Makefile ============================================================================== --- head/x11-fonts/Makefile Sun Jan 5 04:01:01 2020 (r522081) +++ head/x11-fonts/Makefile Sun Jan 5 04:05:28 2020 (r522082) @@ -172,6 +172,7 @@ SUBDIR += oldschool-pc-fonts SUBDIR += open-sans SUBDIR += orbitron + SUBDIR += ots SUBDIR += oxygen-fonts SUBDIR += p5-Font-AFM SUBDIR += p5-Font-TTF Added: head/x11-fonts/ots/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/x11-fonts/ots/Makefile Sun Jan 5 04:05:28 2020 (r522082) @@ -0,0 +1,40 @@ +# Created by: Po-Chuan Hsieh +# $FreeBSD$ + +PORTNAME= ots +PORTVERSION= 8.0.0 +DISTVERSIONPREFIX= v +CATEGORIES= x11-fonts + +MAINTAINER= sunpoet@FreeBSD.org +COMMENT= OpenType Sanitizer + +LICENSE= BSD3CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE + +LIB_DEPENDS= libbrotlidec.so:archivers/brotli \ + libfreetype.so:print/freetype2 \ + libgtest.so:devel/googletest \ + liblz4.so:archivers/liblz4 \ + libwoff2dec.so:devel/woff2 + +USES= compiler:c++11-lang meson pkgconfig shebangfix + +MESON_FALSE= debug +MESON_TRUE= graphite + +GH_ACCOUNT= khaledhosny +USE_GITHUB= yes + +SHEBANG_FILES= tests/*.sh +bash_CMD= ${SH} + +post-patch: + @${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|' ${WRKSRC}/meson.build + +do-test: + ${SETENV} top_builddir=${BUILD_WRKSRC} top_srcdir=${WRKSRC} ${SH} ${WRKSRC}/tests/test_bad_fonts.sh + ${SETENV} top_builddir=${BUILD_WRKSRC} top_srcdir=${WRKSRC} ${SH} ${WRKSRC}/tests/test_fuzzed_fonts.sh + ${SETENV} top_builddir=${BUILD_WRKSRC} top_srcdir=${WRKSRC} ${SH} ${WRKSRC}/tests/test_good_fonts.sh + +.include Added: head/x11-fonts/ots/distinfo ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/x11-fonts/ots/distinfo Sun Jan 5 04:05:28 2020 (r522082) @@ -0,0 +1,3 @@ +TIMESTAMP = 1578125669 +SHA256 (khaledhosny-ots-v8.0.0_GH0.tar.gz) = ced587c1df08fe72d7d5080e3c43f07f80eabca7bde9b31d74a6158ee8be2690 +SIZE (khaledhosny-ots-v8.0.0_GH0.tar.gz) = 28644271 Added: head/x11-fonts/ots/files/patch-meson.build ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/x11-fonts/ots/files/patch-meson.build Sun Jan 5 04:05:28 2020 (r522082) @@ -0,0 +1,183 @@ +--- meson.build.orig 2019-08-30 08:38:31 UTC ++++ meson.build +@@ -1,6 +1,6 @@ + project('ots', 'c', 'cpp', + version: '8.0.0', +- default_options : ['cpp_std=c++11', 'default_library=static'], ++ default_options : ['cpp_std=c++11', 'default_library=both'], + ) + + cxx = meson.get_compiler('cpp') +@@ -38,52 +38,52 @@ configure_file(output: 'config.h', + configuration: conf) + + +-brotli_includes = ['third_party/brotli/c/include'] +-libbrotli = library('brotli', +- 'third_party/brotli/c/common/constants.h', +- 'third_party/brotli/c/common/dictionary.c', +- 'third_party/brotli/c/common/dictionary.h', +- 'third_party/brotli/c/common/transform.c', +- 'third_party/brotli/c/common/transform.h', +- 'third_party/brotli/c/common/version.h', +- 'third_party/brotli/c/dec/bit_reader.c', +- 'third_party/brotli/c/dec/bit_reader.h', +- 'third_party/brotli/c/dec/decode.c', +- 'third_party/brotli/c/dec/huffman.c', +- 'third_party/brotli/c/dec/huffman.h', +- 'third_party/brotli/c/dec/prefix.h', +- 'third_party/brotli/c/dec/state.c', +- 'third_party/brotli/c/dec/state.h', +- 'third_party/brotli/c/include/brotli/decode.h', +- 'third_party/brotli/c/include/brotli/port.h', +- 'third_party/brotli/c/include/brotli/types.h', +- include_directories: include_directories(brotli_includes), +-) ++#brotli_includes = ['third_party/brotli/c/include'] ++#libbrotli = library('brotli', ++# 'third_party/brotli/c/common/constants.h', ++# 'third_party/brotli/c/common/dictionary.c', ++# 'third_party/brotli/c/common/dictionary.h', ++# 'third_party/brotli/c/common/transform.c', ++# 'third_party/brotli/c/common/transform.h', ++# 'third_party/brotli/c/common/version.h', ++# 'third_party/brotli/c/dec/bit_reader.c', ++# 'third_party/brotli/c/dec/bit_reader.h', ++# 'third_party/brotli/c/dec/decode.c', ++# 'third_party/brotli/c/dec/huffman.c', ++# 'third_party/brotli/c/dec/huffman.h', ++# 'third_party/brotli/c/dec/prefix.h', ++# 'third_party/brotli/c/dec/state.c', ++# 'third_party/brotli/c/dec/state.h', ++# 'third_party/brotli/c/include/brotli/decode.h', ++# 'third_party/brotli/c/include/brotli/port.h', ++# 'third_party/brotli/c/include/brotli/types.h', ++# include_directories: include_directories(brotli_includes), ++#) + + +-woff2_includes = ['third_party/brotli/c/include', 'third_party/woff2/include'] +-libwoff2 = library('woff2', +- 'third_party/woff2/include/woff2/decode.h', +- 'third_party/woff2/include/woff2/output.h', +- 'third_party/woff2/src/buffer.h', +- 'third_party/woff2/src/port.h', +- 'third_party/woff2/src/round.h', +- 'third_party/woff2/src/store_bytes.h', +- 'third_party/woff2/src/table_tags.cc', +- 'third_party/woff2/src/table_tags.h', +- 'third_party/woff2/src/variable_length.cc', +- 'third_party/woff2/src/variable_length.h', +- 'third_party/woff2/src/woff2_common.cc', +- 'third_party/woff2/src/woff2_common.h', +- 'third_party/woff2/src/woff2_dec.cc', +- 'third_party/woff2/src/woff2_out.cc', +- include_directories: include_directories(woff2_includes), +-) ++#woff2_includes = ['third_party/brotli/c/include', 'third_party/woff2/include'] ++#libwoff2 = library('woff2', ++# 'third_party/woff2/include/woff2/decode.h', ++# 'third_party/woff2/include/woff2/output.h', ++# 'third_party/woff2/src/buffer.h', ++# 'third_party/woff2/src/port.h', ++# 'third_party/woff2/src/round.h', ++# 'third_party/woff2/src/store_bytes.h', ++# 'third_party/woff2/src/table_tags.cc', ++# 'third_party/woff2/src/table_tags.h', ++# 'third_party/woff2/src/variable_length.cc', ++# 'third_party/woff2/src/variable_length.h', ++# 'third_party/woff2/src/woff2_common.cc', ++# 'third_party/woff2/src/woff2_common.h', ++# 'third_party/woff2/src/woff2_dec.cc', ++# 'third_party/woff2/src/woff2_out.cc', ++# include_directories: include_directories(woff2_includes), ++#) + + + ots_includes = [ + 'include', +- 'third_party/woff2/include', ++ '%%LOCALBASE%%/include/woff2', + ] + + ots_sources = [ +@@ -167,10 +167,10 @@ ots_sources = [ + 'src/vvar.h', + ] + +-ots_libs = [libbrotli, libwoff2] ++#ots_libs = [libbrotli, libwoff2] + + if get_option('graphite') +- ots_includes += ['third_party/lz4/lib'] ++ ots_includes += ['%%LOCALBASE%%/include'] + ots_sources += [ + 'src/feat.cc', + 'src/feat.h', +@@ -186,21 +186,27 @@ if get_option('graphite') + 'src/sill.h', + 'src/sill.cc', + ] +- liblz4 = library('lz4', +- 'third_party/lz4/lib/lz4.c', +- 'third_party/lz4/lib/lz4.h', +- ) +- ots_libs += [liblz4] ++# liblz4 = library('lz4', ++# 'third_party/lz4/lib/lz4.c', ++# 'third_party/lz4/lib/lz4.h', ++# ) ++# ots_libs += [liblz4] + endif + ++libbrotlicommon = dependency('libbrotlicommon') ++libbrotlidec = dependency('libbrotlidec') ++libwoff2common = dependency('libwoff2common') ++libwoff2dec = dependency('libwoff2dec') ++liblz4 = dependency('liblz4') + zlib = dependency('zlib', fallback : ['zlib', 'zlib_dep']) + + libots = library('ots', + ots_sources, + include_directories: include_directories(ots_includes), +- link_with: ots_libs, + cpp_args : '-DHAVE_CONFIG_H', +- dependencies: zlib, ++ dependencies: [libbrotlicommon, libbrotlidec, libwoff2common, libwoff2dec, liblz4, zlib], ++ version : meson.project_version(), ++ install: true, + ) + + +@@ -226,6 +232,7 @@ executable('ots-fuzzer', + cpp_args: fuzzer_defines, + link_with: libots, + link_args: fuzzer_ldflags, ++ install: true, + ) + + +@@ -291,12 +298,13 @@ endif + + + gtest = dependency('gtest', fallback: ['gtest', 'gtest_main_dep']) ++gtest_main = dependency('gtest_main') + + cff_charstring = executable('cff_charstring', + 'tests/cff_charstring_test.cc', + include_directories: include_directories(['include', 'src']), + link_with: libots, +- dependencies: gtest, ++ dependencies: [gtest, gtest_main], + ) + + test('cff_charstring', cff_charstring) +@@ -306,7 +314,7 @@ layout_common_table = executable('layout_common_table' + 'tests/layout_common_table_test.cc', + include_directories: include_directories(['include', 'src']), + link_with: libots, +- dependencies: gtest, ++ dependencies: [gtest, gtest_main], + ) + + test('layout_common_table', layout_common_table) Added: head/x11-fonts/ots/pkg-descr ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/x11-fonts/ots/pkg-descr Sun Jan 5 04:05:28 2020 (r522082) @@ -0,0 +1,11 @@ +The OpenType Sanitizer (OTS) parses and serializes OpenType files (OTF, TTF) and +WOFF and WOFF2 font files, validating them and sanitizing them as it goes. + +The C library is integrated into Chromium and Firefox, and also simple command +line tools to check files offline in a Terminal. + +The CSS font-face property is great for web typography. Having to use images in +order to get the correct typeface is a great sadness; one should be able to use +vectors. + +WWW: https://github.com/khaledhosny/ots Added: head/x11-fonts/ots/pkg-plist ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/x11-fonts/ots/pkg-plist Sun Jan 5 04:05:28 2020 (r522082) @@ -0,0 +1,10 @@ +bin/ots-fuzzer +bin/ots-idempotent +bin/ots-perf +bin/ots-sanitize +bin/ots-side-by-side +bin/ots-validator-checker +lib/libots.a +lib/libots.so +lib/libots.so.8 +lib/libots.so.8.0.0