Add x11-toolkits/py-kivy 1.7.1.
Kivy is a NUI (natural user interface) toolkit that can be used on Android, iOS, Windows, Linux, Mac and *BSD.
This commit is contained in:
parent
0d44442a97
commit
1d28e022a7
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=322115
@ -198,6 +198,7 @@
|
||||
SUBDIR += py-gtkglext
|
||||
SUBDIR += py-gtksourceview
|
||||
SUBDIR += py-gui
|
||||
SUBDIR += py-kivy
|
||||
SUBDIR += py-kiwi
|
||||
SUBDIR += py-pyqwt
|
||||
SUBDIR += py-qt
|
||||
|
147
x11-toolkits/py-kivy/Makefile
Normal file
147
x11-toolkits/py-kivy/Makefile
Normal file
@ -0,0 +1,147 @@
|
||||
# Created by: David Naylor <dbn@FreeBSD.org>
|
||||
# $FreeBSD$
|
||||
|
||||
PORTNAME= kivy
|
||||
PORTVERSION= 1.7.1
|
||||
CATEGORIES= x11-toolkits python
|
||||
MASTER_SITES= LOCAL/dbn/${PORTNAME}
|
||||
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
|
||||
|
||||
MAINTAINER= dbn@FreeBSD.org
|
||||
COMMENT= Python NUI library for rapid application development
|
||||
|
||||
LICENSE= GPLv3
|
||||
|
||||
BUILD_DEPENDS= cython:${PORTSDIR}/lang/cython
|
||||
|
||||
MAKE_ENV= KIVY_NO_CONFIG=yes KIVY_NO_FILELOG=yes PYTHONPATH=${WRKSRC}
|
||||
MAKE_JOBS_UNSAFE= yes # does not (really) use make
|
||||
USE_GITHUB= yes
|
||||
GH_ACCOUNT= ${PORTNAME}
|
||||
GH_COMMIT= ee1985a
|
||||
USE_GL= gl
|
||||
USE_PYDISTUTILS= yes
|
||||
PYDISTUTILS_BUILD_TARGET= build_ext
|
||||
PYDISTUTILS_BUILDARGS= --inplace
|
||||
PYDISTUTILS_EGGINFO= Kivy-${PORTVERSION}-py${PYTHON_VER}.egg-info
|
||||
USE_PYTHON= 2.7
|
||||
|
||||
OPTIONS_DEFINE= DOCS PDF TEST
|
||||
OPTIONS_SET= ENCHANT OPENCV PYGAME # FFMPEG
|
||||
OPTIONS_SUB= yes
|
||||
OPTIONS_GROUP= VIDEO AUDIO IMAGE CAMERA SPELLING CLIPBOARD
|
||||
OPTIONS_MULTI= WINDOW TEXT
|
||||
OPTIONS_MULTI_WINDOW= PYGAME X11 SDL2
|
||||
OPTIONS_MULTI_TEXT= PIL PYGAME SDL2
|
||||
OPTIONS_GROUP_VIDEO= GSTREAMER # FFMPEG
|
||||
OPTIONS_GROUP_AUDIO= GSTREAMER PYGAME SDL
|
||||
OPTIONS_GROUP_IMAGE= PIL PYGAME
|
||||
OPTIONS_GROUP_CAMERA= OPENCV GSTREAMER
|
||||
OPTIONS_GROUP_SPELLING= ENCHANT
|
||||
OPTIONS_GROUP_CLIPBOARD= PYGAME
|
||||
|
||||
.if !defined(ARCH)
|
||||
ARCH!= uname -p
|
||||
.endif
|
||||
.if ${ARCH} == i386
|
||||
OPTIONS_GROUP_VIDEO+= PYGLET
|
||||
.endif
|
||||
|
||||
CAMERA_DESC= Camera support
|
||||
CLIPBOARD_DESC= Clipboard support
|
||||
IMAGE_DESC= Image support
|
||||
SPELLING_DESC= Spell checking support
|
||||
TEXT_DESC= Text rendering support (compulsory)
|
||||
WINDOW_DESC= Window support (compulsory)
|
||||
|
||||
DOCS_BUILD_DEPENDS= sphinx-build:${PORTSDIR}/textproc/py-sphinx
|
||||
ENCHANT_DESC= Spell checking support via Enchant
|
||||
ENCHANT_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}enchant>=0:${PORTSDIR}/textproc/py-enchant
|
||||
GSTREAMER_RUN_DEPENDS= ${PYTHON_SITELIBDIR}/pygst.py:${PORTSDIR}/multimedia/py-gstreamer
|
||||
OPENCV_RUN_DEPENDS= ${PYTHON_SITELIBDIR}/cv.py:${PORTSDIR}/graphics/py-opencv
|
||||
PDF_DESC= Build PDF documentation (required TeXLive, DOCS)
|
||||
PDF_BUILD_DEPENDS= sphinx-build:${PORTSDIR}/textproc/py-sphinx
|
||||
PIL_DESC= Text and window rendering support via PIL
|
||||
PIL_RUN_DEPENDS= ${PYTHON_SITELIBDIR}/PIL:${PORTSDIR}/graphics/py-imaging
|
||||
PYGAME_DESC= Window, text and image rendering support via PyGame
|
||||
PYGAME_RUN_DEPENDS= ${PYTHON_SITELIBDIR}/pygame:${PORTSDIR}/devel/py-game
|
||||
PYGLET_RUN_DEPENDS= ${PYTHON_SITELIBDIR}/pyglet:${PORTSDIR}/graphics/py-pyglet
|
||||
SDL2_DESC= Simple Direct Media Layer v2.0 support
|
||||
SDL2_MAKE_ENV= USE_SDL=1
|
||||
TEST_BUILD_DEPENDS= nosetests:${PORTSDIR}/devel/py-nose
|
||||
TEST_USES= display:build
|
||||
X11_MAKE_ENV+= USE_X11=1
|
||||
|
||||
.if defined(NOT_IMPLEMENTED)
|
||||
FFMPEG_RUN_DEPENDS= ${PYTHON_SITELIBDIR}/ffmpeg:${PORTSDIR}/multimedia/py-ffmpeg
|
||||
.endif
|
||||
|
||||
.include <bsd.port.options.mk>
|
||||
|
||||
.if ${PORT_OPTIONS:MPDF}
|
||||
USE_GMAKE= yes
|
||||
USE_TEX= texlive pdftex:build dvipsk:build
|
||||
.if empty(PORT_OPTIONS:MDOCS)
|
||||
IGNORE= option PDF requires DOCS
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if empty(PORT_OPTIONS:MPYGAME)
|
||||
NOSE_ARGS+= --exclude=test_fbo_pixels
|
||||
.endif
|
||||
|
||||
.if ${PORT_OPTIONS:MSDL2}
|
||||
USE_SDL= sdl2 ttf2 mixer2
|
||||
.endif
|
||||
|
||||
.if ${PORT_OPTIONS:MXORG}
|
||||
USE_XORG= x11
|
||||
.endif
|
||||
|
||||
do-build:
|
||||
@(cd ${WRKSRC}; \
|
||||
${SETENV} ${MAKE_ENV} ${PYTHON_CMD} ${PYSETUP} \
|
||||
${PYDISTUTILS_BUILD_TARGET} ${PYDISTUTILS_BUILDARGS})
|
||||
.if ${PORT_OPTIONS:MTEST}
|
||||
@${RM} -rf kivy/tests/build
|
||||
@(cd ${WRKSRC}; \
|
||||
${SETENV} ${MAKE_ENV} nosetests ${NOSE_ARGS} ${WRKSRC}/kivy/tests)
|
||||
.endif
|
||||
|
||||
.if ${PORT_OPTIONS:MDOCS}
|
||||
post-build-script:
|
||||
${MKDIR} ${WRKSRC}/doc/build/doctrees ${WRKSRC}/doc/build/html \
|
||||
${WRKSRC}/doc/build/latex-a4 ${WRKSRC}/doc/build/latex-letter
|
||||
(cd ${WRKSRC}; \
|
||||
${SETENV} ${MAKE_ENV} ${PYTHON_CMD} doc/autobuild.py)
|
||||
(cd ${WRKSRC}; \
|
||||
${SETENV} ${MAKE_ENV} sphinx-build -b html \
|
||||
-d ${WRKSRC}/doc/build/doctrees \
|
||||
doc/sources ${WRKSRC}/doc/build/html)
|
||||
.if ${PORT_OPTIONS:MPDF}
|
||||
(cd ${WRKSRC}; \
|
||||
${SETENV} ${MAKE_ENV} sphinx-build -b latex \
|
||||
-d ${WRKSRC}/doc/build/doctrees \
|
||||
-D latex_paper=a4 doc/sources ${WRKSRC}/doc/build/latex-a4)
|
||||
(cd ${WRKSRC}; \
|
||||
${SETENV} ${MAKE_ENV} sphinx-build -b latex \
|
||||
-d ${WRKSRC}/doc/build/doctrees \
|
||||
-D latex_paper=letter doc/sources ${WRKSRC}/doc/build/latex-letter)
|
||||
${SETENV} ${MAKE_ENV} ${GMAKE} -C ${WRKSRC}/doc/build/latex-a4 \
|
||||
all-pdf > /dev/null
|
||||
${SETENV} ${MAKE_ENV} ${GMAKE} -C ${WRKSRC}/doc/build/latex-letter \
|
||||
all-pdf > /dev/null
|
||||
.endif
|
||||
|
||||
post-install:
|
||||
${MKDIR} ${DOCSDIR}
|
||||
(cd ${WRKSRC}/doc/build/html; ${COPYTREE_SHARE} . ${DOCSDIR})
|
||||
.if ${PORT_OPTIONS:MPDF}
|
||||
${INSTALL_DATA} ${WRKSRC}/doc/build/latex-a4/Kivy.pdf \
|
||||
${DOCSDIR}/Kivy-a4.pdf
|
||||
${INSTALL_DATA} ${WRKSRC}/doc/build/latex-letter/Kivy.pdf \
|
||||
${DOCSDIR}/Kivy-letter.pdf
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.include <bsd.port.mk>
|
2
x11-toolkits/py-kivy/distinfo
Normal file
2
x11-toolkits/py-kivy/distinfo
Normal file
@ -0,0 +1,2 @@
|
||||
SHA256 (kivy-1.7.1.tar.gz) = ba255ebf473e0d620a5696a88e4e3f9d101090ffed610425133387736cb15640
|
||||
SIZE (kivy-1.7.1.tar.gz) = 13962259
|
54
x11-toolkits/py-kivy/files/patch-setup.py
Normal file
54
x11-toolkits/py-kivy/files/patch-setup.py
Normal file
@ -0,0 +1,54 @@
|
||||
--- setup.py.orig 2013-05-28 15:08:56.000000000 +0200
|
||||
+++ setup.py 2013-06-11 19:33:06.000000000 +0200
|
||||
@@ -6,9 +6,10 @@
|
||||
import sys
|
||||
from copy import deepcopy
|
||||
from os.path import join, dirname, sep, exists
|
||||
-from os import walk, environ
|
||||
+from os import walk, environ, path
|
||||
from distutils.core import setup
|
||||
from distutils.extension import Extension
|
||||
+from subprocess import check_output
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Determine on which platform we are
|
||||
@@ -124,7 +125,7 @@
|
||||
c_options['use_glew'] = True
|
||||
else:
|
||||
# searching GLES headers
|
||||
- default_header_dirs = ['/usr/include', '/usr/local/include']
|
||||
+ default_header_dirs = ['/usr/include', path.join(environ.get('LOCALBASE', '/usr/local'), 'include')]
|
||||
found = False
|
||||
for hdir in default_header_dirs:
|
||||
filename = join(hdir, 'GLES2', 'gl2.h')
|
||||
@@ -201,6 +202,9 @@
|
||||
sysroot = '/System/Library/Frameworks/ApplicationServices.framework/Frameworks'
|
||||
flags['extra_compile_args'] += ['-F%s' % sysroot]
|
||||
flags['extra_link_args'] += ['-F%s' % sysroot]
|
||||
+ elif platform.startswith('freebsd'):
|
||||
+ flags['include_dirs'] += [path.join(environ.get('LOCALBASE', '/usr/local'), 'include')]
|
||||
+ flags['extra_link_args'] += ['-L', path.join(environ.get('LOCALBASE', '/usr/local'), 'lib')]
|
||||
return flags
|
||||
|
||||
def determine_gl_flags():
|
||||
@@ -214,8 +218,6 @@
|
||||
flags['extra_link_args'] = ['-framework', 'OpenGL', '-arch', 'x86_64']
|
||||
flags['extra_compile_args'] = ['-arch', 'x86_64']
|
||||
elif platform.startswith('freebsd'):
|
||||
- flags['include_dirs'] = ['/usr/local/include']
|
||||
- flags['extra_link_args'] = ['-L', '/usr/local/lib']
|
||||
flags['libraries'] = ['GL']
|
||||
elif platform.startswith('openbsd'):
|
||||
flags['include_dirs'] = ['/usr/X11R6/include']
|
||||
@@ -283,6 +285,11 @@
|
||||
elif platform == 'darwin':
|
||||
flags['extra_link_args'] += [
|
||||
'-framework', 'ApplicationServices']
|
||||
+ elif platform.startswith('freebsd'):
|
||||
+ flags['extra_compile_args'] = check_output([environ.get('SDL2_CONFIG', 'sdl2-config'), '--cflags']).split()
|
||||
+ flags['extra_link_args'] = check_output([environ.get('SDL2_CONFIG', 'sdl2-config'), '--libs']).split()
|
||||
+ flags['include_dirs'] = []
|
||||
+ flags['libraries'] = ["SDL2_ttf", "SDL2_mixer"]
|
||||
return flags
|
||||
|
||||
def determine_graphics_pxd():
|
22
x11-toolkits/py-kivy/pkg-descr
Normal file
22
x11-toolkits/py-kivy/pkg-descr
Normal file
@ -0,0 +1,22 @@
|
||||
Cross platform
|
||||
==============
|
||||
Kivy is running on Linux, Windows, MacOSX, Android and IOS. You can run the
|
||||
same code on all supported platforms. It can use natively most inputs
|
||||
protocols and devices like WM_Touch, WM_Pen, Mac OS X Trackpad and Magic Mouse,
|
||||
Mtdev, Linux Kernel HID, TUIO. A multi-touch mouse simulator is included.
|
||||
|
||||
Business Friendly
|
||||
=================
|
||||
Kivy is 100% free to use, under LGPL 3 licence. The toolkit is professionally
|
||||
developed, backed and used. You can use it in a product and sell your product.
|
||||
The framework is stable and has a documented API, plus a programming guide to
|
||||
help for in the first step.
|
||||
|
||||
GPU Accelerated
|
||||
===============
|
||||
The graphics engine is built over OpenGL ES 2, using modern and fast way of
|
||||
doing graphics. The toolkit is coming with more than 20 widgets designed to be
|
||||
extensible. Many parts are written in C using Cython, tested with regression
|
||||
tests.
|
||||
|
||||
WWW: http://kivy.org
|
1485
x11-toolkits/py-kivy/pkg-plist
Normal file
1485
x11-toolkits/py-kivy/pkg-plist
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user