source: trunk/dports/ruby/rb-sqlite/Portfile @ 8209

Last change on this file since 8209 was 8209, checked in by rshaw, 15 years ago

Fixes depends_lib to be depends_lib-append to be compatible with Ruby group
code fix to properly handle dependencies.
Revision bump.

  • Property svn:eol-style set to native
File size: 1.5 KB
Line 
1# $Id: Portfile,v 1.11 2004/09/08 00:38:54 rshaw Exp $
2PortSystem              1.0
3PortGroup               ruby 1.0
4
5ruby.setup              {sqlite sqlite-ruby} 1.3.0 basic_install.rb {README samples} \
6                                rubyforge:974
7revision                1
8maintainers             rshaw@opendarwin.org
9description             Interface to the SQLite DB engine from Ruby
10long_description        Provides an interface for the SQLite DB engine. This \
11                                        differs from the 'ruby-sqlite' project (also on RAA) \
12                                        in that it is more complete, and from the ruby DBI \
13                                        version of SQLite in that it is SQLite specific, so \
14                                        you can do things that would otherwise be more \
15                                        difficult via DBI. If you want portability between \
16                                        backends, use DBI. If you want ease of use with \
17                                        SQLite, use this.
18categories-append       databases
19checksums               md5 fe4f56d695a17141d3619b043d54cd37
20platforms               darwin
21
22depends_lib-append              lib:libsqlite:sqlite
23
24post-patch {
25        reinplace "s|ruby extconf.rb|${ruby.bin} -rvendor-specific extconf.rb|" \
26                ${worksrcpath}/install.rb
27        reinplace "s|make install|& DESTDIR=${destroot}|" \
28                ${worksrcpath}/install.rb
29        reinplace "s|make|& RUBY=${ruby.bin}|" \
30                ${worksrcpath}/install.rb
31}
32
33test.run                yes
34test {
35        if {[file exists ${destroot}${ruby.lib}/sqlite.rb]} {
36                cd ${worksrcpath}
37                set cmd "${ruby.bin} \
38                        -I${destroot}${ruby.lib} \
39                        -I${destroot}${ruby.archlib}"
40                system "${cmd} samples/define_db.rb"
41                system "${cmd} samples/advanced.rb"
42                system "${cmd} samples/queries.rb"
43                #system "${cmd} samples/pragma.rb"
44        } else {
45                ui_error "Must run 'destroot' prior to 'test' for port ${name}!"
46                exit 1
47        }
48}
49test.target
50
Note: See TracBrowser for help on using the repository browser.