blob: c2448c2d94faa658ee8e933fe63c54628fb7d5f8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
inherit eutils toolchain-funcs
KEYWORDS="~x86"
DESCRIPTION="SQL C++ code generator (to use with dev-db/*wrapped packages)"
HOMEPAGE="http://www.alhem.net/project/sql2class/index.html"
SRC_URI="http://www.alhem.net/project/sql2class/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
IUSE="mysql sqlite"
DEPEND=""
RDEPEND=""
src_unpack() {
unpack ${A}
cd "${S}"
sed -i \
-e 's/\(CPPFLAGS\) =/\1+=/' \
-e 's/-Wall -O2 -g//' \
-e 's#/usr/devel#/usr#' \
-e 's/g++/$(CXX)/' \
Makefile || die "sed failed"
}
src_compile() {
emake CXX="$(tc-getCXX)" || die "emake failed"
}
src_install() {
dobin sql2class
dodoc README
}
pkg_postinst() {
elog "You might want to emerge one of the following packages as well:"
elog "-> dev-db/mysqlwrapped ... to use the generated code with a MySQL-DB"
elog "-> dev-db/sqlitewrapped ... to use the generated code with SQLite"
}
|