[solvespace] 03/03: Use system packaged unifont.
Anton Gladky
gladk at moszumanska.debian.org
Mon Aug 15 20:16:02 UTC 2016
This is an automated email from the git hooks/post-receive script.
gladk pushed a commit to branch master
in repository solvespace.
commit 9ac1e9fd2c18d6bcae276b819cc27d34c471f9bb
Author: Anton Gladky <gladk at debian.org>
Date: Mon Aug 15 22:15:09 2016 +0200
Use system packaged unifont.
---
debian/control | 2 +-
debian/patches/20_use_system_unifont.patch | 56 ++++++++++++++++++++++++++++++
debian/patches/series | 1 +
3 files changed, 58 insertions(+), 1 deletion(-)
diff --git a/debian/control b/debian/control
index be09a21..3ad677d 100644
--- a/debian/control
+++ b/debian/control
@@ -4,7 +4,7 @@ Priority: optional
Maintainer: whitequark <whitequark at whitequark.org>
Build-Depends: debhelper (>= 9), cmake, libpng-dev, zlib1g-dev, libjson-c-dev,
libfontconfig1-dev, libgtkmm-2.4-dev, libpangomm-1.4-dev,
- libgl-dev, libglu-dev, libglew-dev
+ libgl-dev, libglu-dev, libglew-dev, unifont
Standards-Version: 3.9.5
Homepage: http://solvespace.com
Vcs-Git: git://github.com/whitequark/solvespace
diff --git a/debian/patches/20_use_system_unifont.patch b/debian/patches/20_use_system_unifont.patch
new file mode 100644
index 0000000..2ece363
--- /dev/null
+++ b/debian/patches/20_use_system_unifont.patch
@@ -0,0 +1,56 @@
+Description: Use system packaged unifont
+Author: Anton Gladky <gladk at debian.org>
+Last-Update: 2016-08-15
+
+Index: solvespace/src/CMakeLists.txt
+===================================================================
+--- solvespace.orig/src/CMakeLists.txt
++++ solvespace/src/CMakeLists.txt
+@@ -101,10 +101,10 @@ add_custom_command(
+ OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/generated/bitmapfont.table.h
+ COMMAND $<TARGET_FILE:unifont2c>
+ ${CMAKE_CURRENT_BINARY_DIR}/generated/bitmapfont.table.h
+- ${CMAKE_CURRENT_SOURCE_DIR}/fonts/unifont-8.0.01.hex.gz
++ /usr/share/unifont/unifont.hex
+ ${chars}
+ DEPENDS unifont2c
+- ${CMAKE_CURRENT_SOURCE_DIR}/fonts/unifont-8.0.01.hex.gz
++ /usr/share/unifont/unifont.hex
+ ${chars}
+ VERBATIM)
+
+Index: solvespace/tools/unifont2c.cpp
+===================================================================
+--- solvespace.orig/tools/unifont2c.cpp
++++ solvespace/tools/unifont2c.cpp
+@@ -118,17 +118,17 @@ int main(int argc, char** argv) {
+ properties[codepoint].exists = true;
+ }
+
+- gzFile unifont = gzopen(argv[2], "rb");
++ FILE *unifont = fopen(argv[2], "rb");
+ if(!unifont)
+ die("unifont fopen failed");
+
+ while(1) {
+ char buf[100];
+- if(!gzgets(unifont, buf, sizeof(buf))){
+- if(gzeof(unifont)) {
++ if(!fgets(buf, sizeof(buf), unifont)){
++ if(feof(unifont)) {
+ break;
+ } else {
+- die("unifont gzgets failed");
++ die("unifont gets failed");
+ }
+ }
+
+@@ -164,7 +164,7 @@ int main(int argc, char** argv) {
+ properties[codepoint].isWide = isWide;
+ }
+
+- gzclose(unifont);
++ fclose(unifont);
+
+ FILE *source = fopen(argv[1], "wt");
+ if(!source)
diff --git a/debian/patches/series b/debian/patches/series
index 1f20572..ebc2025 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
01_RemoveGitHash.patch
+20_use_system_unifont.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/solvespace.git
More information about the debian-science-commits
mailing list