Skip to content

Commit 17404f5

Browse files
committed
Upgrade to support native compiling on Ruby 1.9.x.
This patch has a number of fixes including: * using the new gem/bundler gemspec format * removing jewler * RSTRING_PTR(arg) instead of RSTRING(arg)->ptr * adds Gemfile * adds .gitignore * fixes Rakefile * converted all docs to markdown * added MIT license
1 parent feb7400 commit 17404f5

12 files changed

+242
-220
lines changed

.gitignore

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
*.gem
2+
*.rbc
3+
.bundle
4+
.config
5+
.yardoc
6+
Gemfile.lock
7+
InstalledFiles
8+
_yardoc
9+
coverage
10+
doc/
11+
lib/bundler/man
12+
pkg
13+
rdoc
14+
spec/reports
15+
test/tmp
16+
test/version_tmp
17+
tmp

ChangeLog CHANGELOG.md

+18-8
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,41 @@
1+
CHANGELOG
2+
=========
3+
4+
v0.1.4
5+
------
6+
* Upgraded C-extension to compile natively on Ruby 1.9
7+
8+
Old Changelog
9+
-------------
10+
111
Thu Aug 15 09:39:24 2002, pabs <[email protected]>
2-
* created changelog.
12+
* created changelog
313

4-
Tue Nov 12 17:20:23 2002, pabs <[email protected]
14+
Tue Nov 12 17:20:23 2002, pabs <[email protected]>
515
* made some changes according to the notes in the freetype2 headers:
616
* ft2.c: removed FT2::PixelMode::RGB and FT2::PixelMode::RGBA constants
717
* ft2.c: removed Ft2::PaletteMode
818
* compiles clean with -W -Wall -pedantic again
919

10-
Fri Nov 15 03:27:50 2002, pabs <[email protected]
20+
Fri Nov 15 03:27:50 2002, pabs <[email protected]>
1121
* ft2.c: finished documentation for FT2::Face methods.
1222

13-
Fri Nov 15 03:52:46 2002, pabs <[email protected]
23+
Fri Nov 15 03:52:46 2002, pabs <[email protected]>
1424
* ft2.c: added FT2::Face#current_charmap
1525

16-
Fri Nov 15 15:15:37 2002, pabs <[email protected]
26+
Fri Nov 15 15:15:37 2002, pabs <[email protected]>
1727
* ft2.c: finished documentation for FT2::GlyphMetrics methods.
1828

19-
Sat Nov 16 01:45:42 2002, pabs <[email protected]
29+
Sat Nov 16 01:45:42 2002, pabs <[email protected]>
2030
* ft2.c: finished documentation for FT2::GlyphSlot methods.
2131

22-
Wed Nov 20 16:11:10 2002, pabs <[email protected]
32+
Wed Nov 20 16:11:10 2002, pabs <[email protected]>
2333
* ft2.c: finished documenting the FT2::SizeMetrics methods (had to
2434
pull the documentation for them out of the second part of the
2535
FreeType2 tutorial, since they're not available in the API
2636
reference).
2737

28-
Thu Nov 21 15:18:26 2002, pabs <[email protected]
38+
Thu Nov 21 15:18:26 2002, pabs <[email protected]>
2939
* ft2.c: finished documenting and implementing FT2::Glyph,
3040
FT2::BitmapGlyph, and FT2::OutlineGlyph.
3141
* ft2.c: compiles clean with -W -Wall -pedantic again

Gemfile

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
source :rubygems
2+
3+
gemspec

LICENSE

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
Copyright (c) 2012 Paul Duncan
2+
3+
MIT License
4+
5+
Permission is hereby granted, free of charge, to any person obtaining
6+
a copy of this software and associated documentation files (the
7+
"Software"), to deal in the Software without restriction, including
8+
without limitation the rights to use, copy, modify, merge, publish,
9+
distribute, sublicense, and/or sell copies of the Software, and to
10+
permit persons to whom the Software is furnished to do so, subject to
11+
the following conditions:
12+
13+
The above copyright notice and this permission notice shall be
14+
included in all copies or substantial portions of the Software.
15+
16+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

MANIFEST

-14
This file was deleted.

README README.md

+4-7
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,14 @@
1-
FT2-Ruby 0.1.0 README
2-
=====================
1+
FT2-Ruby
2+
========
33

44
This document was last updated on Sat Nov 16 17:51:41 2002. Please see
55
http://www.pablotron.org/software/ft2-ruby/ for the latest version of
66
this software.
77

8-
Introduction
8+
Installation
99
============
10-
hum de dum dum
1110

12-
Installing FT2-Ruby
13-
===================
14-
blah de blah blah
11+
gem install ft2-ruby
1512

1613
About the Author
1714
================

Rakefile

+1-32
Original file line numberDiff line numberDiff line change
@@ -1,32 +1 @@
1-
require 'rubygems'
2-
require 'rake'
3-
4-
begin
5-
require 'jeweler'
6-
Jeweler::Tasks.new do |gem|
7-
gem.name = "ft2-ruby"
8-
gem.summary = %Q{Ruby libraries to FreeType2}
9-
gem.email = "[email protected]"
10-
gem.homepage = "http://www.pablotron.org/"
11-
gem.authors = ["Paul Duncan"]
12-
gem.extensions = ["extconf.rb"]
13-
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
14-
end
15-
Jeweler::GemcutterTasks.new
16-
rescue LoadError
17-
puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
18-
end
19-
20-
#
21-
# task :default => :test
22-
#
23-
require 'rake/rdoctask'
24-
Rake::RDocTask.new do |rdoc|
25-
version = File.exist?('VERSION') ? File.read('VERSION') : ""
26-
27-
rdoc.rdoc_dir = 'rdoc'
28-
rdoc.title = "ft2-ruby #{version}"
29-
rdoc.rdoc_files.include('README')
30-
rdoc.rdoc_files.include('TODO')
31-
rdoc.rdoc_files.include('ft2.c')
32-
end
1+
require 'bundler/gem_tasks'

TODO TODO.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
TODO
2+
====
3+
14
* fixed point data conversions
25
* face subglyph handling
36
* test test test test!

VERSION

-1
This file was deleted.

extconf.rb

-1
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,3 @@
77

88
have_library("freetype", "FT_Init_FreeType") and
99
create_makefile("ft2")
10-

ft2-ruby.gemspec

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
Gem::Specification.new do |gem|
2+
gem.authors = ["Paul Duncan"]
3+
gem.email = "[email protected]"
4+
gem.description = %Q{Ruby libraries to FreeType2}
5+
gem.summary = %Q{Ruby libraries to FreeType2}
6+
gem.homepage = "http://www.pablotron.org/"
7+
8+
gem.files = `git ls-files`.split($\)
9+
gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
10+
gem.extensions = ['extconf.rb']
11+
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
12+
gem.name = "ft2-ruby"
13+
gem.version = '0.1.4'
14+
15+
gem.add_development_dependency 'bundler'
16+
gem.add_development_dependency 'rake'
17+
end

0 commit comments

Comments
 (0)