fizx-parsley-ruby 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/README +0 -0
- data/ext/extconf.rb +67 -0
- metadata +74 -0
data/README
ADDED
File without changes
|
data/ext/extconf.rb
ADDED
@@ -0,0 +1,67 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
ENV["ARCHFLAGS"] = "-arch #{`uname -p` =~ /powerpc/ ? 'ppc' : 'i386'}"
|
3
|
+
|
4
|
+
require 'mkmf'
|
5
|
+
|
6
|
+
ROOT = File.expand_path(File.join(File.dirname(__FILE__), '..'))
|
7
|
+
LIBDIR = Config::CONFIG['libdir']
|
8
|
+
INCLUDEDIR = Config::CONFIG['includedir']
|
9
|
+
|
10
|
+
$CFLAGS << " #{ENV["CFLAGS"]}"
|
11
|
+
if Config::CONFIG['target_os'] == 'mingw32'
|
12
|
+
$CFLAGS << " -DXP_WIN -DXP_WIN32"
|
13
|
+
else
|
14
|
+
$CFLAGS << " -g -DXP_UNIX"
|
15
|
+
end
|
16
|
+
|
17
|
+
$CFLAGS << " -O3 -Wall -Wextra -Wcast-qual -Wwrite-strings -Wconversion -Wmissing-noreturn -Winline"
|
18
|
+
|
19
|
+
if Config::CONFIG['target_os'] == 'mingw32'
|
20
|
+
find_library('xml2', 'xmlParseDoc',
|
21
|
+
File.join(ROOT, 'cross', 'libxml2-2.7.2.win32', 'bin'))
|
22
|
+
find_library('xslt', 'xsltParseStylesheetDoc',
|
23
|
+
File.join(ROOT, 'cross', 'libxslt-1.1.24.win32', 'bin'))
|
24
|
+
else
|
25
|
+
find_library('xml2', 'xmlParseDoc', LIBDIR)
|
26
|
+
find_library('xslt', 'xsltParseStylesheetDoc', LIBDIR)
|
27
|
+
end
|
28
|
+
|
29
|
+
|
30
|
+
if Config::CONFIG['target_os'] == 'mingw32'
|
31
|
+
header = File.join(ROOT, 'cross', 'libxml2-2.7.2.win32', 'include')
|
32
|
+
unless find_header('libxml/xmlversion.h', header)
|
33
|
+
abort "need libxml"
|
34
|
+
end
|
35
|
+
|
36
|
+
header = File.join(ROOT, 'cross', 'libxslt-1.1.24.win32', 'include')
|
37
|
+
unless find_header('libxslt/libxslt.h', header)
|
38
|
+
abort "need libxslt"
|
39
|
+
end
|
40
|
+
|
41
|
+
header = File.join(ROOT, 'cross', 'iconv-1.9.2.win32', 'include')
|
42
|
+
unless find_header('iconv.h', header)
|
43
|
+
abort "need iconv"
|
44
|
+
end
|
45
|
+
else
|
46
|
+
unless find_header('libxml/xmlversion.h',
|
47
|
+
File.join(INCLUDEDIR, "libxml2"), '/usr/include/libxml2'
|
48
|
+
)
|
49
|
+
abort "need libxml"
|
50
|
+
end
|
51
|
+
unless find_header('libxslt/xslt.h', INCLUDEDIR, '/usr/include')
|
52
|
+
abort "need libxslt"
|
53
|
+
end
|
54
|
+
|
55
|
+
version = try_constant('LIBXML_VERSION', 'libxml/xmlversion.h')
|
56
|
+
end
|
57
|
+
|
58
|
+
myincl = %w[/usr/local/include /opt/local/include /usr/include]
|
59
|
+
mylib = %w[/usr/local/lib /opt/local/lib /usr/lib]
|
60
|
+
|
61
|
+
find_header('json/json.h', INCLUDEDIR, *myincl) or abort "need json/json.h"
|
62
|
+
find_library('json', 'json_object_new_string', LIBDIR, *mylib) or abort "need libjson"
|
63
|
+
|
64
|
+
find_header('parsley.h', INCLUDEDIR, *myincl) or abort "need parsley.h"
|
65
|
+
find_library('parsley', 'parsley_compile', LIBDIR, *mylib) or abort "need libparsley"
|
66
|
+
|
67
|
+
create_makefile('cparsley')
|
metadata
ADDED
@@ -0,0 +1,74 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: fizx-parsley-ruby
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Kyle Maxwell
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
|
12
|
+
date: 2008-08-10 00:00:00 -07:00
|
13
|
+
default_executable:
|
14
|
+
dependencies:
|
15
|
+
- !ruby/object:Gem::Dependency
|
16
|
+
name: json
|
17
|
+
type: :runtime
|
18
|
+
version_requirement:
|
19
|
+
version_requirements: !ruby/object:Gem::Requirement
|
20
|
+
requirements:
|
21
|
+
- - ">"
|
22
|
+
- !ruby/object:Gem::Version
|
23
|
+
version: 0.0.0
|
24
|
+
version:
|
25
|
+
description: Ruby binding for parsley
|
26
|
+
email: kyle@kylemaxwell.com
|
27
|
+
executables: []
|
28
|
+
|
29
|
+
extensions:
|
30
|
+
- ext/extconf.rb
|
31
|
+
extra_rdoc_files:
|
32
|
+
- README
|
33
|
+
files:
|
34
|
+
- ./ext/cparsley.c
|
35
|
+
- ./ext/extconf.rb
|
36
|
+
- ./lib/parsley.rb
|
37
|
+
- ./parsley-ruby.gemspec
|
38
|
+
- ./README
|
39
|
+
- ./test/test_dexterous.rb
|
40
|
+
- ./test/yelp-benchmark.rb
|
41
|
+
- ./test/yelp-home.html
|
42
|
+
- ./test/yelp-home.let
|
43
|
+
- ./test/yelp.html
|
44
|
+
- README
|
45
|
+
has_rdoc: true
|
46
|
+
homepage: http://github.com/fizx/parsley-ruby
|
47
|
+
post_install_message:
|
48
|
+
rdoc_options:
|
49
|
+
- --main
|
50
|
+
- README
|
51
|
+
require_paths:
|
52
|
+
- lib
|
53
|
+
- ext
|
54
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
55
|
+
requirements:
|
56
|
+
- - ">="
|
57
|
+
- !ruby/object:Gem::Version
|
58
|
+
version: "0"
|
59
|
+
version:
|
60
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
61
|
+
requirements:
|
62
|
+
- - ">="
|
63
|
+
- !ruby/object:Gem::Version
|
64
|
+
version: "0"
|
65
|
+
version:
|
66
|
+
requirements: []
|
67
|
+
|
68
|
+
rubyforge_project:
|
69
|
+
rubygems_version: 1.2.0
|
70
|
+
signing_key:
|
71
|
+
specification_version: 2
|
72
|
+
summary: Ruby binding for parsley
|
73
|
+
test_files: []
|
74
|
+
|