diff options
author | Baptiste Daroussin <bapt@FreeBSD.org> | 2015-03-22 22:16:56 +0000 |
---|---|---|
committer | Baptiste Daroussin <bapt@FreeBSD.org> | 2015-03-22 22:16:56 +0000 |
commit | c136e6a41436c82f3848fcba412d584630ff7711 (patch) | |
tree | e549ae19d06859dfd0935f10e0897251b1ceb843 /x11-fonts | |
parent | 8bef511d9b9090dee9c39d7123dbeec7ec38f3ae (diff) | |
download | ports-c136e6a41436c82f3848fcba412d584630ff7711.tar.gz ports-c136e6a41436c82f3848fcba412d584630ff7711.zip |
Notes
Diffstat (limited to 'x11-fonts')
-rw-r--r-- | x11-fonts/Makefile | 1 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/Makefile | 26 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/distinfo | 2 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/files/patch-Makefile | 41 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/files/patch-builtin.cpp | 11 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/files/patch-directory.cpp | 47 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/files/patch-encoding.cpp | 79 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/files/patch-encoding.h | 12 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/files/patch-encoding.l | 44 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/files/patch-ttf.cpp | 83 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/files/patch-ttf.h | 37 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/files/patch-util.h | 10 | ||||
-rw-r--r-- | x11-fonts/ttmkfdir/pkg-descr | 4 |
13 files changed, 0 insertions, 397 deletions
diff --git a/x11-fonts/Makefile b/x11-fonts/Makefile index e9e20dc38373..2d95304ff502 100644 --- a/x11-fonts/Makefile +++ b/x11-fonts/Makefile @@ -162,7 +162,6 @@ SUBDIR += tkfont SUBDIR += tlwg-ttf SUBDIR += tmu - SUBDIR += ttmkfdir SUBDIR += tv-fonts SUBDIR += ubuntu-font SUBDIR += urwfonts diff --git a/x11-fonts/ttmkfdir/Makefile b/x11-fonts/ttmkfdir/Makefile deleted file mode 100644 index 4dcdd35de498..000000000000 --- a/x11-fonts/ttmkfdir/Makefile +++ /dev/null @@ -1,26 +0,0 @@ -# Created by: Thomas Gellekum <tg@FreeBSD.org> -# $FreeBSD$ - -PORTNAME= ttmkfdir -PORTVERSION= 3.0.9 -PORTREVISION= 3 -PORTEPOCH= 1 -CATEGORIES= x11-fonts -MASTER_SITES= ${MASTER_SITE_GENTOO}/distfiles/ \ - http://www.skysmurf.nl/comp/FreeBSD/distfiles/ - -MAINTAINER= freebsd@skysmurf.nl -COMMENT= Create fonts.scale file for use with TrueType font server - -LICENSE= LGPL21 - -LIB_DEPENDS= libfreetype.so:${PORTSDIR}/print/freetype2 - -PLIST_FILES= bin/ttmkfdir -USE_XORG= x11 -USES= gmake tar:bzip2 - -do-install: - ${INSTALL_PROGRAM} ${WRKSRC}/ttmkfdir ${STAGEDIR}${PREFIX}/bin - -.include <bsd.port.mk> diff --git a/x11-fonts/ttmkfdir/distinfo b/x11-fonts/ttmkfdir/distinfo deleted file mode 100644 index 3f98addcbc41..000000000000 --- a/x11-fonts/ttmkfdir/distinfo +++ /dev/null @@ -1,2 +0,0 @@ -SHA256 (ttmkfdir-3.0.9.tar.bz2) = c65f8e2ba5522c896df2eb7256852bf0a5855109deec0f874379474ef76c1c1c -SIZE (ttmkfdir-3.0.9.tar.bz2) = 20160 diff --git a/x11-fonts/ttmkfdir/files/patch-Makefile b/x11-fonts/ttmkfdir/files/patch-Makefile deleted file mode 100644 index a379aea3f16d..000000000000 --- a/x11-fonts/ttmkfdir/files/patch-Makefile +++ /dev/null @@ -1,41 +0,0 @@ ---- Makefile.orig Mon Dec 9 19:07:14 2002 -+++ Makefile Wed Jul 19 11:35:12 2006 -@@ -16,7 +16,6 @@ - RELEASE=$(shell rpm -q --qf "%{release}\n" --specfile $(NAME).spec | head -1) - - CVSTAG = r$(subst .,_,$(VERSION)) --CVSROOT = $(shell cat CVS/Root) - - # Autodetec the proper command used to build RPM packages - RPMBUILD=$(shell [ -x /usr/bin/rpmbuild ] && echo rpmbuild || echo rpm) -@@ -24,11 +23,8 @@ - FREETYPE_INCL=$(shell freetype-config --cflags) - FREETYPE_LIB=$(shell freetype-config --libs) - --OPTFLAGS= --DEBUG=-ggdb --CXX=g++ --CXXFLAGS=-Wall -pedantic $(FREETYPE_INCL) $(DEBUG) $(OPTFLAGS) --LDFLAGS=$(FREETYPE_LIB) $(DEBUG) -+CXXFLAGS+=-Wall $(FREETYPE_INCL) -+LDFLAGS+=$(FREETYPE_LIB) -lz - - DESTDIR= - PREFIX=/usr -@@ -39,13 +35,13 @@ - all: ttmkfdir - - .cpp.o: -- libtool --mode=compile $(CXX) $(CXXFLAGS) -o $@ -c $^ -+ $(CXX) $(CXXFLAGS) -o $@ -c $^ - - ttmkfdir: ttmkfdir.o directory.o commandline.o ttf.o encoding.o parser.o builtin.o -- libtool --mode=link $(CXX) -o $@ $^ $(LDFLAGS) -+ $(CXX) -o $@ $^ $(LDFLAGS) - - parser.cpp: encoding.l -- flex -i -8 -o$@ $< -+ lex -i -8 -o$@ $< - - install: - mkdir -p $(DESTDIR)$(BINDIR) diff --git a/x11-fonts/ttmkfdir/files/patch-builtin.cpp b/x11-fonts/ttmkfdir/files/patch-builtin.cpp deleted file mode 100644 index 15092fe683ff..000000000000 --- a/x11-fonts/ttmkfdir/files/patch-builtin.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- builtin.cpp.orig Mon Jan 13 04:11:10 2003 -+++ builtin.cpp Wed Jul 19 11:27:41 2006 -@@ -600,7 +600,7 @@ - 0x00f8, 0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd, 0x00fe, 0x00ff - }; - --}; -+} - - Encoding::BuiltinEncoding_t Encoding::builtin_encodings[] = { - {256,191,32,{TT_PLATFORM_MICROSOFT,TT_MS_ID_UNICODE_CS,iso8859_1},{"iso8859-1",}}, diff --git a/x11-fonts/ttmkfdir/files/patch-directory.cpp b/x11-fonts/ttmkfdir/files/patch-directory.cpp deleted file mode 100644 index a0b35b7fbb20..000000000000 --- a/x11-fonts/ttmkfdir/files/patch-directory.cpp +++ /dev/null @@ -1,47 +0,0 @@ ---- directory.cpp.orig 2002-12-09 03:29:11.000000000 -0500 -+++ directory.cpp -@@ -1,7 +1,10 @@ - #include <cctype> - #include <dirent.h> -+#include <sys/types.h> - #include <sys/stat.h> - #include <unistd.h> -+#include <fcntl.h> -+#include <string.h> - - #include "directory.h" - -@@ -37,19 +40,24 @@ directory::select (const char *name) con - bool - ttfdirectory::select (const char *name) const - { -- int len; -+ int fd; -+ unsigned int n; - struct stat buf; -+ char sigdata[8]; -+ char TTsig[] = "\000\001\000\000\000", OTsig[] = "OTTO"; - - /* must be a regular file */ - if (::stat (name, &buf) || !(S_ISREG (buf.st_mode))) { - return false; - } -- -- /* we make the decision by the extension of the file name */ -- return (((len = strlen (name)) > 4) && -- (name[len - 4] == '.') && -- (std::toupper(name[len - 3]) == 'T') && -- (std::toupper(name[len - 2]) == 'T') && -- ((std::toupper(name[len - 1]) == 'F') || -- (std::toupper(name[len - 1]) == 'C'))); -+ -+ fd = ::open(name, O_RDONLY); -+ if (fd < 0) return false; -+ n = read(fd, sigdata, sizeof(sigdata)); -+ close(fd); -+ if (n < sizeof(sigdata)) -+ return false; -+ -+ return (!memcmp(sigdata, TTsig, 5) -+ || !memcmp(sigdata, OTsig, 4)); - } diff --git a/x11-fonts/ttmkfdir/files/patch-encoding.cpp b/x11-fonts/ttmkfdir/files/patch-encoding.cpp deleted file mode 100644 index 871ea696642f..000000000000 --- a/x11-fonts/ttmkfdir/files/patch-encoding.cpp +++ /dev/null @@ -1,79 +0,0 @@ ---- encoding.cpp.orig Wed Jul 19 11:30:05 2006 -+++ encoding.cpp Wed Jul 19 11:30:28 2006 -@@ -2,7 +2,9 @@ - #include <cstdio> - #include <cstdlib> - #include <cstring> --#include "freetype/freetype.h" -+#include <unistd.h> -+#include <zlib.h> -+#include <ft2build.h> - - #include "ttmkfdir.h" - #include "encoding.h" -@@ -32,9 +34,16 @@ - NextFile (FILE *f, char *name) - { - char file_name [1024]; -- char command[1024]; -+ char line_buf [1024]; -+ char tmp_file_name[] = "/tmp/ttmkfdir_XXXXXX"; -+ char inbuf[300000]; -+ FILE *od; -+ gzFile fd; -+ int rvalue, tmpfd; - -- if (fscanf (f, "%*s %[^\n]\n", file_name) == 1) { -+ if (fgets (line_buf, sizeof(line_buf), f) != NULL) { -+ -+ sscanf (line_buf, "%*s %[^\n]\n", file_name); - - if (file_name[0] == '/') { - name[0] = 0; -@@ -44,9 +53,25 @@ - - strcat (name, file_name); - -- sprintf (command, "exec %s < %s", (toupper(name[strlen (name) - 1]) == 'Z') -- ? "gzip -d" : "cat", name); -- return popen (command, "r"); -+ bzero(inbuf, sizeof(inbuf)); -+ -+ fd = gzopen (name,"rb"); -+ rvalue = gzread (fd, inbuf, sizeof(inbuf)); -+ -+ tmpfd = mkstemp (tmp_file_name); -+ if (tmpfd == -1) { -+ return 0; -+ } -+ -+ od = fdopen (tmpfd,"w"); -+ fputs (inbuf, od); -+ fflush (od); -+ fclose (od); -+ -+ od = fopen (tmp_file_name,"r"); -+ unlink (tmp_file_name); -+ return od; -+ - } - - return 0; -@@ -75,7 +100,7 @@ - yyrestart (input); - yylex (name, *this); - -- pclose (input); -+ fclose (input); - } - - fclose (f); -@@ -97,7 +122,7 @@ - - NumericMapping *m = new NumericMapping (size, b->mapdata.platform, b->mapdata.encoding); - -- for (int i = 0; i < size; i++) -+ for (unsigned int i = 0; i < size; i++) - (*m)[i] = b->mapdata.mappingtable[i]; - - AddMapping (m); diff --git a/x11-fonts/ttmkfdir/files/patch-encoding.h b/x11-fonts/ttmkfdir/files/patch-encoding.h deleted file mode 100644 index 9f0f53ae57b2..000000000000 --- a/x11-fonts/ttmkfdir/files/patch-encoding.h +++ /dev/null @@ -1,12 +0,0 @@ ---- encoding.h.orig Tue Mar 12 15:41:27 2002 -+++ encoding.h Sun Mar 21 22:35:15 2004 -@@ -6,7 +6,8 @@ - #include <map> - #include <string> - --#include "freetype/freetype.h" -+#include <ft2build.h> -+#include FT_FREETYPE_H - - #include "util.h" - diff --git a/x11-fonts/ttmkfdir/files/patch-encoding.l b/x11-fonts/ttmkfdir/files/patch-encoding.l deleted file mode 100644 index 574cdbb3f1be..000000000000 --- a/x11-fonts/ttmkfdir/files/patch-encoding.l +++ /dev/null @@ -1,44 +0,0 @@ ---- encoding.l.orig Wed Jul 19 11:39:18 2006 -+++ encoding.l Wed Jul 19 11:39:22 2006 -@@ -8,7 +8,7 @@ - #include "ttmkfdir.h" - #include "encoding.h" - --#define DEFAULT_SIZE 0x100 /* 8 bit encoding */ -+#define DEFAULT_SIZE 0xFFFF /* 8 bit encoding */ - #define YY_DECL int yylex (char *current_file, Encodings_t &dest) - - static unsigned int line_number = 1; -@@ -43,6 +43,7 @@ - STARTENCODING{WHITESPACES}{STRING} { - cur_enc = new Encoding; - cur_enc->names.push_back (strip_first (yytext)); -+ cur_enc->size = DEFAULT_SIZE; - BEGIN(INSIDE_ENC_BLOCK); - } - -@@ -97,6 +98,7 @@ - <INSIDE_MAP_BLOCK>UNDEFINE{WHITESPACES}{NUMBER}({WHITESPACES}{NUMBER})? { - char *startptr = strip_first (yytext); - char *endptr; -+ long msize = cur_map->size(); - - int i1 = std::strtol (startptr, &endptr, 0); - startptr = endptr; -@@ -108,13 +110,14 @@ - } - - /* now mark all the unassigned codes */ -- for (long i = i1; i <= i2; i++) { -+ for (long i = i1; i <= i2 && i < msize; i++) { - (*cur_map)[i] = -1; - } - } - - <INSIDE_MAP_BLOCK>{NUMBER}({WHITESPACES}{NUMBER}){0,2} { -- int numbers[3], i = 0, start_range, end_range, target, res; -+ int numbers[3], target, res; -+ unsigned int i = 0, start_range, end_range; - char *startptr; - char *endptr = yytext; - diff --git a/x11-fonts/ttmkfdir/files/patch-ttf.cpp b/x11-fonts/ttmkfdir/files/patch-ttf.cpp deleted file mode 100644 index da260f32bd09..000000000000 --- a/x11-fonts/ttmkfdir/files/patch-ttf.cpp +++ /dev/null @@ -1,83 +0,0 @@ ---- ttf.cpp.orig 2003-01-08 06:25:25.000000000 +0100 -+++ ttf.cpp 2013-12-17 00:08:13.000000000 +0100 -@@ -3,7 +3,8 @@ - #include <cctype> - #include <cstring> - --#include "freetype/tttables.h" -+#include <ft2build.h> -+#include FT_TRUETYPE_TABLES_H - #include "ttmkfdir.h" - #include "ttf.h" - #include "ttos2val.h" -@@ -51,20 +52,27 @@ - bool - Face::MappingPresent (int cmapidx, NumericMapping *m, int enc_size, int start_code, bool enc_comp) - { -- int idx, missing = 0; -+ int idx; -+ unsigned int missing = 0, bail_at, msize; -+ - FT_Set_Charmap (face, face->charmaps[cmapidx]); - -- for (unsigned int i = start_code; i < m->size (); i++) { -+ msize = m->size(); -+ if (enc_size <= 256) { -+ bail_at = int (cmdline::instance()->option ("max-missing")); -+ } else { -+ bail_at = ((int (cmdline::instance()->option ("max-missing-percentage")) -+& enc_comp)*enc_size)/100; -+ } -+ -+ for (unsigned int i = start_code; i < msize && missing < bail_at; i++) { - if ((*m)[i] < 0) - continue; - if ((idx = FT_Get_Char_Index (face, (*m)[i])) == 0) - missing++; - } -- if (enc_size <= 256) { -- return (missing <= int (cmdline::instance()->option ("max-missing"))); -- } else { -- return ((100 * missing/enc_size) <= int (cmdline::instance()->option ("max-missing-percentage")) & enc_comp); -- } -+ -+ return missing < bail_at; - } - - Face::Face (const std::string &filename) -@@ -239,7 +247,7 @@ - for (i = 0; i < n; i++) { - if ((fterror = FT_Get_Sfnt_Name (face, i, &NamePtr)) != FT_Err_Ok) { - std::cout << "Warning: Can't SFNT name : " << FileName << "(" << fterror << ")" << std::endl; -- return; -+ return NULL; - }; - platform = NamePtr.platform_id; - encoding = NamePtr.encoding_id; -@@ -483,7 +491,7 @@ - const char * - Face::PanoseWeight (void) const - { -- static char *panose_weight_latin[] = { -+ static const char *panose_weight_latin[] = { - "any", - "no fit", - "very light", -@@ -548,7 +556,7 @@ - const char * - Face::PanoseWidth (void) const - { -- static char *panose_spacing_latin_text [] = { -+ static const char *panose_spacing_latin_text [] = { - "any", - "no fit", - "old style", -@@ -561,7 +569,7 @@ - "monospaced", - }; - -- static char *panose_spacing_latin_decorative [] = { -+ static const char *panose_spacing_latin_decorative [] = { - "any", - "no fit", - "super condensed", diff --git a/x11-fonts/ttmkfdir/files/patch-ttf.h b/x11-fonts/ttmkfdir/files/patch-ttf.h deleted file mode 100644 index dabeee1f3848..000000000000 --- a/x11-fonts/ttmkfdir/files/patch-ttf.h +++ /dev/null @@ -1,37 +0,0 @@ ---- ttf.h.orig Wed Jul 19 11:36:47 2006 -+++ ttf.h Wed Jul 19 11:36:50 2006 -@@ -3,16 +3,19 @@ - #define TTF_H__ - - #include <string> --#include "freetype/freetype.h" --#include "freetype/tttables.h" --#include "freetype/ftsnames.h" --#include "freetype/ttnameid.h" --#include "freetype/fterrors.h" --#include "freetype/ftmodule.h" -+#include <ft2build.h> -+#include FT_FREETYPE_H -+#include FT_TRUETYPE_TABLES_H -+#include FT_SFNT_NAMES_H -+#include FT_TRUETYPE_IDS_H -+#include FT_ERRORS_H -+#include FT_MODULE_H - - #include "util.h" - #include "encoding.h" - -+using namespace std; -+ - namespace ttf { - - class Face { -@@ -49,7 +52,7 @@ - TT_Postscript *post; - std::string FileName; - }; --}; -+} - - #endif /* TTF_H__ */ - diff --git a/x11-fonts/ttmkfdir/files/patch-util.h b/x11-fonts/ttmkfdir/files/patch-util.h deleted file mode 100644 index 7c6f6dd9548d..000000000000 --- a/x11-fonts/ttmkfdir/files/patch-util.h +++ /dev/null @@ -1,10 +0,0 @@ ---- util.h.orig Mon Dec 9 11:29:11 2002 -+++ util.h Wed Jul 19 11:27:37 2006 -@@ -17,6 +17,6 @@ - Singleton (void) {}; - ~Singleton (void) {}; - }; --}; -+} - - #endif // TTMKFDIRUTIL_H__ diff --git a/x11-fonts/ttmkfdir/pkg-descr b/x11-fonts/ttmkfdir/pkg-descr deleted file mode 100644 index f35a3a1eba7b..000000000000 --- a/x11-fonts/ttmkfdir/pkg-descr +++ /dev/null @@ -1,4 +0,0 @@ -This program reads TrueType fonts and creates a -suitable fonts.scale file for use with an X font server. - -WWW: http://people.redhat.com/yshao/ |