File: setup.py

package info (click to toggle)
pyfribidi 0.6-2
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 440 kB
  • ctags: 66
  • sloc: sh: 2,920; ansic: 168; python: 165; makefile: 14
file content (37 lines) | stat: -rw-r--r-- 1,044 bytes parent folder | download | duplicates (2)
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
#!/usr/bin/env python

from distutils.core import setup
from distutils.extension import Extension
import os

def _getpkgconfigvalue(value, package="fribidi"):
	""" get a value from pkg-config for package (default: fribidi)
	    param value: long-option to pkg-config
	"""
	f = os.popen("pkg-config --%s %s" % (value, package))
	x = f.readline().strip()
	f.close()

	# generators: 2.4+ only :(
	#return list(y[2:] for y in x.split(" "))

	l = []
	for y in x.split(" "):
		l.append(y[2:])
	return l

setup (name = "pyfribidi",
        version = "0.6.0",
        description = "Python libfribidi interface",
        author = "Yaacov Zamir, Nir Soffer",
        author_email = "kzamir@walla.co.il",
        url = "http://hspell-gui.sourceforge.net/pyfribidi.html",
        license = "GPL",

        ext_modules = [ Extension(
                name = 'pyfribidi',
                sources = ['pyfribidi.c'],
                libraries = _getpkgconfigvalue("libs-only-l"),
                include_dirs = _getpkgconfigvalue("cflags-only-I")
        )]
)