[HarfBuzz] harfbuzz: Branch 'master' - 8 commits
Behdad Esfahbod
behdad at kemper.freedesktop.org
Mon Feb 12 23:13:09 UTC 2018
.ci/trigger-coverity.sh | 13 +++++++++++
.travis.yml | 13 +++++++++++
CMakeLists.txt | 11 +++++++--
configure.ac | 13 ++++++-----
src/Makefile.am | 54 +++++++++++++++++++++++++++++++++++++-----------
src/check-defs.sh | 12 ++++------
src/gen-def.py | 9 +++++---
7 files changed, 94 insertions(+), 31 deletions(-)
New commits:
commit 0b94d590d971de0b44b0db941c7a3e095f15fbc9
Author: Khaled Hosny <khaledhosny at eglug.org>
Date: Mon Feb 12 16:45:36 2018 +0200
Rename --with-stdcpp → --with-libstdc++
Also improve wording a bit and fix make check in --with-libstdc++=yes.
diff --git a/configure.ac b/configure.ac
index f77e0874..d8c38fe2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -57,11 +57,12 @@ m4_define([hb_libtool_current],
HB_LIBTOOL_VERSION_INFO=hb_libtool_current:hb_libtool_revision:hb_libtool_age
AC_SUBST(HB_LIBTOOL_VERSION_INFO)
-AC_ARG_WITH([stdcpp],
- [AS_HELP_STRING([--with-stdcpp],
- [Do not try suppressing linkage to libstdcpp])],,
- [with_stdcpp=no])
-AM_CONDITIONAL(WITHSTDCPP, [test "x$with_stdcpp" = "xyes"])
+AC_ARG_WITH([libstdc++],
+ [AS_HELP_STRING([--with-libstdc++=@<:@yes/no@:>@],
+ [Allow linking with libstdc++ @<:@default=no@:>@])],
+ [with_libstdcxx=$withval],
+ [with_libstdcxx=no])
+AM_CONDITIONAL(WITH_LIBSTDCXX, [test "x$with_libstdcxx" = "xyes"])
# Documentation
have_gtk_doc=false
diff --git a/src/Makefile.am b/src/Makefile.am
index 25728563..7b7ccdef 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -30,7 +30,7 @@ HBSOURCES += $(HB_BASE_RAGEL_GENERATED_sources)
HBHEADERS = $(HB_BASE_headers)
HBNODISTHEADERS = $(HB_NODIST_headers)
-if !WITHSTDCPP
+if !WITH_LIBSTDCXX
# Make sure we don't link to libstdc++
HBCFLAGS += -fno-rtti -fno-exceptions
@@ -128,7 +128,7 @@ export_symbols_subset = -export-symbols harfbuzz-subset.def
harfbuzz_subset_def_dependency = harfbuzz-subset.def
choosed_linker = $(CXXLINK)
else
-if WITHSTDCPP
+if WITH_LIBSTDCXX
choosed_linker = $(CXXLINK)
else
if HAVE_GCC
@@ -340,11 +340,16 @@ dist_check_SCRIPTS = \
check-externs.sh \
check-header-guards.sh \
check-includes.sh \
- check-libstdc++.sh \
check-static-inits.sh \
check-symbols.sh \
$(NULL)
+if !WITH_LIBSTDCXX
+dist_check_SCRIPTS += \
+ check-libstdc++.sh \
+ $(NULL)
+endif
+
check_PROGRAMS = \
test-ot-tag \
$(NULL)
commit 91f0d51f0525097fef6173046379a89414cb515f
Author: Ebrahim Byagowi <ebrahim at gnu.org>
Date: Mon Feb 12 17:20:12 2018 +0330
Fix symbol exporting issue on msys2 and ✅ bringing all the bots (#781)
diff --git a/src/Makefile.am b/src/Makefile.am
index 48e63320..25728563 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -126,20 +126,24 @@ export_symbols_icu = -export-symbols harfbuzz-icu.def
harfbuzz_icu_def_dependency = harfbuzz-icu.def
export_symbols_subset = -export-symbols harfbuzz-subset.def
harfbuzz_subset_def_dependency = harfbuzz-subset.def
-libharfbuzz_la_LINK = $(CXXLINK) $(libharfbuzz_la_LDFLAGS)
+choosed_linker = $(CXXLINK)
else
if WITHSTDCPP
-libharfbuzz_la_LINK = $(CXXLINK) $(libharfbuzz_la_LDFLAGS)
+choosed_linker = $(CXXLINK)
else
if HAVE_GCC
# Use a C linker for GCC, not C++; Don't link to libstdc++
-libharfbuzz_la_LINK = $(LINK) $(libharfbuzz_la_LDFLAGS)
+choosed_linker = $(LINK)
else
-libharfbuzz_la_LINK = $(CXXLINK) $(libharfbuzz_la_LDFLAGS)
+choosed_linker = $(CXXLINK)
endif
endif
endif
+libharfbuzz_la_LINK = $(choosed_linker) $(libharfbuzz_la_LDFLAGS)
+libharfbuzz_icu_la_LINK = $(choosed_linker) $(libharfbuzz_icu_la_LDFLAGS)
+libharfbuzz_subset_la_LINK = $(choosed_linker) $(libharfbuzz_subset_la_LDFLAGS)
+
base_link_flags = $(AM_LDFLAGS) -lm -version-info $(HB_LIBTOOL_VERSION_INFO) -no-undefined
libharfbuzz_la_SOURCES = $(HBSOURCES) $(HBHEADERS) $(HBNODISTHEADERS)
libharfbuzz_la_CPPFLAGS = $(HBCFLAGS)
@@ -153,7 +157,6 @@ pkgconfig_DATA = harfbuzz.pc
EXTRA_DIST += harfbuzz.pc.in
lib_LTLIBRARIES += libharfbuzz-subset.la
-libharfbuzz_subset_la_LINK = $(libharfbuzz_la_LINK)
libharfbuzz_subset_la_SOURCES = $(HB_SUBSET_sources)
libharfbuzz_subset_la_CPPFLAGS = $(libharfbuzz_la_CPPFLAGS)
libharfbuzz_subset_la_LDFLAGS = $(base_link_flags) $(export_symbols_subset)
@@ -191,7 +194,6 @@ HBSOURCES += $(HB_ICU_sources)
HBHEADERS += $(HB_ICU_headers)
else
lib_LTLIBRARIES += libharfbuzz-icu.la
-libharfbuzz_icu_la_LINK = $(libharfbuzz_la_LINK)
libharfbuzz_icu_la_SOURCES = $(HB_ICU_sources)
libharfbuzz_icu_la_CPPFLAGS = $(libharfbuzz_la_CPPFLAGS) $(ICU_CFLAGS)
libharfbuzz_icu_la_LDFLAGS = $(base_link_flags) $(export_symbols_icu)
commit 133e17fe2335abb77f61dbf1cff1955c21334137
Author: Ebrahim Byagowi <ebrahim at gnu.org>
Date: Mon Feb 12 15:24:22 2018 +0330
Minor
diff --git a/src/check-defs.sh b/src/check-defs.sh
index 71b8f021..ade59357 100755
--- a/src/check-defs.sh
+++ b/src/check-defs.sh
@@ -18,6 +18,7 @@ tested=false
for def in harfbuzz.def harfbuzz-icu.def harfbuzz-subset.def; do
if ! test -f "$def"; then
echo "check-defs.sh: '$def' not found; skipping test it"
+ continue
fi
lib=`echo "$def" | sed 's/[.]def$//;s at .*/@@'`
for suffix in so dylib; do
commit 16f5b53eec4c3238cf92438a17e6dc532e8a61f5
Author: Ebrahim Byagowi <ebrahim at gnu.org>
Date: Mon Feb 12 15:18:13 2018 +0330
Minor, don't skip the whole test when one .def file not found
diff --git a/src/check-defs.sh b/src/check-defs.sh
index 71c90971..71b8f021 100755
--- a/src/check-defs.sh
+++ b/src/check-defs.sh
@@ -17,8 +17,7 @@ fi
tested=false
for def in harfbuzz.def harfbuzz-icu.def harfbuzz-subset.def; do
if ! test -f "$def"; then
- echo "check-defs.sh: '$def' not found; skipping test"
- exit 77
+ echo "check-defs.sh: '$def' not found; skipping test it"
fi
lib=`echo "$def" | sed 's/[.]def$//;s at .*/@@'`
for suffix in so dylib; do
commit a9b650d38407f6f2a26d8386e801600b1004d5d6
Author: Ebrahim Byagowi <ebrahim at gnu.org>
Date: Mon Feb 12 15:10:13 2018 +0330
Apply check-defs.sh to -icu and -subset, toward mingw fix (#780)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index d1f2e087..d23fc2df 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -836,8 +836,11 @@ if (UNIX OR MINGW)
add_test(NAME check-symbols.sh COMMAND ${PROJECT_SOURCE_DIR}/src/check-symbols.sh)
add_test(NAME check-defs.sh COMMAND ${PROJECT_SOURCE_DIR}/src/check-defs.sh)
- set_tests_properties(check-static-inits.sh check-libstdc++.sh check-symbols.sh check-defs.sh
- PROPERTIES ENVIRONMENT "libs=.;srcdir=${PROJECT_SOURCE_DIR}/src")
+ set_tests_properties(
+ check-static-inits.sh check-libstdc++.sh check-symbols.sh check-defs.sh
+ PROPERTIES
+ ENVIRONMENT "libs=.;srcdir=${PROJECT_SOURCE_DIR}/src"
+ SKIP_RETURN_CODE 77)
endif ()
add_test(NAME check-c-linkage-decls.sh COMMAND ./check-c-linkage-decls.sh)
@@ -846,7 +849,9 @@ if (UNIX OR MINGW)
add_test(NAME check-includes.sh COMMAND ./check-includes.sh)
set_tests_properties(
check-c-linkage-decls.sh check-header-guards.sh check-externs.sh check-includes.sh
- PROPERTIES WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}/src)
+ PROPERTIES
+ WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}/src
+ SKIP_RETURN_CODE 77)
endif ()
# Needs to come last so that variables defined above are passed to
diff --git a/src/Makefile.am b/src/Makefile.am
index 44df7465..48e63320 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -122,6 +122,10 @@ HBLIBS += $(HBNONPCLIBS)
if OS_WIN32
export_symbols = -export-symbols harfbuzz.def
harfbuzz_def_dependency = harfbuzz.def
+export_symbols_icu = -export-symbols harfbuzz-icu.def
+harfbuzz_icu_def_dependency = harfbuzz-icu.def
+export_symbols_subset = -export-symbols harfbuzz-subset.def
+harfbuzz_subset_def_dependency = harfbuzz-subset.def
libharfbuzz_la_LINK = $(CXXLINK) $(libharfbuzz_la_LDFLAGS)
else
if WITHSTDCPP
@@ -136,9 +140,10 @@ endif
endif
endif
+base_link_flags = $(AM_LDFLAGS) -lm -version-info $(HB_LIBTOOL_VERSION_INFO) -no-undefined
libharfbuzz_la_SOURCES = $(HBSOURCES) $(HBHEADERS) $(HBNODISTHEADERS)
libharfbuzz_la_CPPFLAGS = $(HBCFLAGS)
-libharfbuzz_la_LDFLAGS = $(AM_LDFLAGS) -lm -version-info $(HB_LIBTOOL_VERSION_INFO) $(export_symbols) -no-undefined
+libharfbuzz_la_LDFLAGS = $(base_link_flags) $(export_symbols)
libharfbuzz_la_LIBADD = $(HBLIBS)
EXTRA_libharfbuzz_la_DEPENDENCIES = $(harfbuzz_def_dependency)
pkginclude_HEADERS = $(HBHEADERS)
@@ -151,8 +156,9 @@ lib_LTLIBRARIES += libharfbuzz-subset.la
libharfbuzz_subset_la_LINK = $(libharfbuzz_la_LINK)
libharfbuzz_subset_la_SOURCES = $(HB_SUBSET_sources)
libharfbuzz_subset_la_CPPFLAGS = $(libharfbuzz_la_CPPFLAGS)
-libharfbuzz_subset_la_LDFLAGS = $(libharfbuzz_la_LDFLAGS)
+libharfbuzz_subset_la_LDFLAGS = $(base_link_flags) $(export_symbols_subset)
libharfbuzz_subset_la_LIBADD = libharfbuzz.la
+EXTRA_libharfbuzz_subset_la_DEPENDENCIES = $(harfbuzz_subset_def_dependency)
pkginclude_HEADERS += $(HB_SUBSET_headers)
pkgconfig_DATA += harfbuzz-subset.pc
EXTRA_DIST += harfbuzz-subset.pc.in
@@ -188,8 +194,9 @@ lib_LTLIBRARIES += libharfbuzz-icu.la
libharfbuzz_icu_la_LINK = $(libharfbuzz_la_LINK)
libharfbuzz_icu_la_SOURCES = $(HB_ICU_sources)
libharfbuzz_icu_la_CPPFLAGS = $(libharfbuzz_la_CPPFLAGS) $(ICU_CFLAGS)
-libharfbuzz_icu_la_LDFLAGS = $(libharfbuzz_la_LDFLAGS)
+libharfbuzz_icu_la_LDFLAGS = $(base_link_flags) $(export_symbols_icu)
libharfbuzz_icu_la_LIBADD = $(ICU_LIBS) libharfbuzz.la
+EXTRA_libharfbuzz_icu_la_DEPENDENCIES = $(harfbuzz_icu_def_dependency)
pkginclude_HEADERS += $(HB_ICU_headers)
pkgconfig_DATA += harfbuzz-icu.pc
endif
@@ -245,9 +252,13 @@ EXTRA_DIST += \
CLEANFILES += $(pkgconfig_DATA)
-CLEANFILES += harfbuzz.def
+CLEANFILES += harfbuzz.def harfbuzz-icu.def harfbuzz-subset.def
harfbuzz.def: $(HBHEADERS) $(HBNODISTHEADERS)
$(AM_V_GEN) headers="$^" $(srcdir)/gen-def.py $@
+harfbuzz-icu.def: $(HB_ICU_headers)
+ $(AM_V_GEN) headers="$^" $(srcdir)/gen-def.py $@
+harfbuzz-subset.def: $(HB_SUBSET_headers)
+ $(AM_V_GEN) headers="$^" $(srcdir)/gen-def.py $@
GENERATORS = \
@@ -319,7 +330,7 @@ test_buffer_serialize_SOURCES = test-buffer-serialize.cc
test_buffer_serialize_CPPFLAGS = $(HBCFLAGS)
test_buffer_serialize_LDADD = libharfbuzz.la $(HBLIBS)
-check: harfbuzz.def # For check-defs.sh
+check: harfbuzz.def harfbuzz-icu.def harfbuzz-subset.def # For check-defs.sh
dist_check_SCRIPTS = \
check-c-linkage-decls.sh \
diff --git a/src/check-defs.sh b/src/check-defs.sh
index adb90a72..71c90971 100755
--- a/src/check-defs.sh
+++ b/src/check-defs.sh
@@ -14,14 +14,12 @@ else
exit 77
fi
-defs="harfbuzz.def"
-if ! test -f "$defs"; then
- echo "check-defs.sh: '$defs' not found; skipping test"
- exit 77
-fi
-
tested=false
-for def in $defs; do
+for def in harfbuzz.def harfbuzz-icu.def harfbuzz-subset.def; do
+ if ! test -f "$def"; then
+ echo "check-defs.sh: '$def' not found; skipping test"
+ exit 77
+ fi
lib=`echo "$def" | sed 's/[.]def$//;s at .*/@@'`
for suffix in so dylib; do
so=$libs/lib${lib}.$suffix
diff --git a/src/gen-def.py b/src/gen-def.py
index ad1606ec..1673537c 100755
--- a/src/gen-def.py
+++ b/src/gen-def.py
@@ -9,8 +9,11 @@ for h in os.environ["headers"].split (' '):
if h.endswith (".h"):
with io.open(h, encoding='utf8') as f: headers_content.append (f.read ())
-result = ("EXPORTS\n" +
- "\n".join (sorted (re.findall (r"^hb_\w+(?= \()", "\n".join (headers_content), re.M))) +
- "\nLIBRARY libharfbuzz-0.dll")
+result = """EXPORTS
+%s
+LIBRARY lib%s-0.dll""" % (
+ "\n".join (sorted (re.findall (r"^hb_\w+(?= \()", "\n".join (headers_content), re.M))),
+ sys.argv[1].replace ('.def', '')
+)
with open (sys.argv[1], "w") as f: f.write (result)
commit 2efc8965506d8fd31934be1dba3322f922f3409d
Author: Ebrahim Byagowi <ebrahim at gnu.org>
Date: Mon Feb 12 12:00:07 2018 +0330
Add --with-stdcpp for ossfuzzer and mupdf use (#770)
diff --git a/configure.ac b/configure.ac
index 5a17cc1a..f77e0874 100644
--- a/configure.ac
+++ b/configure.ac
@@ -57,6 +57,12 @@ m4_define([hb_libtool_current],
HB_LIBTOOL_VERSION_INFO=hb_libtool_current:hb_libtool_revision:hb_libtool_age
AC_SUBST(HB_LIBTOOL_VERSION_INFO)
+AC_ARG_WITH([stdcpp],
+ [AS_HELP_STRING([--with-stdcpp],
+ [Do not try suppressing linkage to libstdcpp])],,
+ [with_stdcpp=no])
+AM_CONDITIONAL(WITHSTDCPP, [test "x$with_stdcpp" = "xyes"])
+
# Documentation
have_gtk_doc=false
m4_ifdef([GTK_DOC_CHECK], [
@@ -80,12 +86,6 @@ if test "x$GCC" = "xyes"; then
# Make symbols link locally
LDFLAGS="$LDFLAGS -Bsymbolic-functions"
- # Make sure we don't link to libstdc++
- CXXFLAGS="$CXXFLAGS -fno-rtti -fno-exceptions"
-
- # No threadsafe statics and C++ as we do it ourselves
- CXXFLAGS="$CXXFLAGS -fno-threadsafe-statics"
-
# Assorted warnings
CXXFLAGS="$CXXFLAGS -Wcast-align"
diff --git a/src/Makefile.am b/src/Makefile.am
index 88862832..44df7465 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -30,6 +30,14 @@ HBSOURCES += $(HB_BASE_RAGEL_GENERATED_sources)
HBHEADERS = $(HB_BASE_headers)
HBNODISTHEADERS = $(HB_NODIST_headers)
+if !WITHSTDCPP
+# Make sure we don't link to libstdc++
+HBCFLAGS += -fno-rtti -fno-exceptions
+
+# No threadsafe statics and C++ as we do it ourselves
+HBCFLAGS += -fno-threadsafe-statics
+endif
+
if HAVE_OT
HBSOURCES += $(HB_OT_sources)
HBSOURCES += $(HB_OT_RAGEL_GENERATED_sources)
@@ -116,13 +124,17 @@ export_symbols = -export-symbols harfbuzz.def
harfbuzz_def_dependency = harfbuzz.def
libharfbuzz_la_LINK = $(CXXLINK) $(libharfbuzz_la_LDFLAGS)
else
-# Use a C linker for GCC, not C++; Don't link to libstdc++
+if WITHSTDCPP
+libharfbuzz_la_LINK = $(CXXLINK) $(libharfbuzz_la_LDFLAGS)
+else
if HAVE_GCC
+# Use a C linker for GCC, not C++; Don't link to libstdc++
libharfbuzz_la_LINK = $(LINK) $(libharfbuzz_la_LDFLAGS)
else
libharfbuzz_la_LINK = $(CXXLINK) $(libharfbuzz_la_LDFLAGS)
endif
endif
+endif
libharfbuzz_la_SOURCES = $(HBSOURCES) $(HBHEADERS) $(HBNODISTHEADERS)
libharfbuzz_la_CPPFLAGS = $(HBCFLAGS)
commit 82e04758c895ce2cd6bddde5f72e592c718fcb69
Author: Ebrahim Byagowi <ebrahim at gnu.org>
Date: Mon Feb 12 11:56:32 2018 +0330
minor
diff --git a/.travis.yml b/.travis.yml
index 56117255..e2de5038 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -77,7 +77,6 @@ addons:
- libgraphite2-dev # for extra shapers
#- libgirepository1.0-dev # for gobject-introspection
-addons:
coverity_scan:
project:
name: harfbuzz/harfbuzz
@@ -86,4 +85,4 @@ addons:
notification_email: harfbuzz at lists.freedesktop.org
build_command_prepend: ./autogen.sh --with-freetype --with-glib --with-gobject --with-cairo --with-icu --with-graphite2
build_command: make
- branch_pattern: coverity_scan
\ No newline at end of file
+ branch_pattern: coverity_scan
commit 7daa2822f6320801dfed09782ae46687e7c8cbb3
Author: Ebrahim Byagowi <ebrahim at gnu.org>
Date: Mon Feb 12 11:27:00 2018 +0330
Add Travis based Coverity trigger (#778)
diff --git a/.ci/trigger-coverity.sh b/.ci/trigger-coverity.sh
new file mode 100644
index 00000000..e2416922
--- /dev/null
+++ b/.ci/trigger-coverity.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+set -x
+set -o errexit -o nounset
+
+if test "x$TRAVIS_EVENT_TYPE" != x"cron"; then exit; fi
+
+BRANCH="$TRAVIS_BRANCH"
+if test "x$BRANCH" != xmaster; then exit; fi
+
+git fetch --unshallow
+git remote add upstream "https://$GH_TOKEN@github.com/harfbuzz/harfbuzz.git"
+git push -q upstream master:coverity_scan
diff --git a/.travis.yml b/.travis.yml
index 5516e711..56117255 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -11,6 +11,8 @@ env:
- LDFLAGS="--coverage"
- CONFIGURE_OPTS="--with-freetype --with-glib --with-gobject --with-cairo --with-icu --with-graphite2"
- NOCONFIGURE=1
+ # COVERITY_SCAN_TOKEN
+ - secure: "MRJtVu/fQoWNwMAamvIJBCX/1SMvEuEUk/ljAif/y2/3syyWgxFGp17UGnDILdoZYyCqTM+jQciY2P0nVqbjjOAUlML4QOAalqw8kPp8iTsnHUe+KOMVrOVP6p6qAQxk1im1O41cCMkmVKvk+NXe/on5euz6LGF2laHZaOAMoes="
matrix:
include:
@@ -28,6 +30,7 @@ matrix:
after_success:
- bash .ci/run-coveralls.sh # for coveralls.io code coverage tracking
- bash .ci/deploy-docs.sh
+ - bash .ci/trigger-coverity.sh
- os: linux
compiler: clang
@@ -73,3 +76,14 @@ addons:
- libicu-dev # for extra unicode functions
- libgraphite2-dev # for extra shapers
#- libgirepository1.0-dev # for gobject-introspection
+
+addons:
+ coverity_scan:
+ project:
+ name: harfbuzz/harfbuzz
+ version: 1.0
+ description: HarfBuzz OpenType text shaping engine
+ notification_email: harfbuzz at lists.freedesktop.org
+ build_command_prepend: ./autogen.sh --with-freetype --with-glib --with-gobject --with-cairo --with-icu --with-graphite2
+ build_command: make
+ branch_pattern: coverity_scan
\ No newline at end of file
More information about the HarfBuzz
mailing list