1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-14 03:10:47 +00:00

New port: devel/py-llvmcpy: Python bindings for LLVM auto-generated from the LLVM-C API

This module allows you to use llvm from Python.
You can use most modern llvm versions, selecting them during runtime.
It uses py-cffi to generate ELF binaries during runtime.

Submitted by:	myself
Approved by:	tcberner (mentor)
Differential Revision:	https://reviews.freebsd.org/D13724
This commit is contained in:
Yuri Victorovich 2018-01-15 10:37:33 +00:00
parent 3e7acf54b8
commit 8ed156eb79
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=459030
4 changed files with 41 additions and 0 deletions

View File

@ -4568,6 +4568,7 @@
SUBDIR += py-libzfs
SUBDIR += py-linecache2
SUBDIR += py-llfuse
SUBDIR += py-llvmcpy
SUBDIR += py-llvmlite
SUBDIR += py-lock_file
SUBDIR += py-lockfile

30
devel/py-llvmcpy/Makefile Normal file
View File

@ -0,0 +1,30 @@
# $FreeBSD$
PORTNAME= llvmcpy
DISTVERSIONPREFIX= v
DISTVERSION= 0.1.1-8
DISTVERSIONSUFFIX= -g6635c3a
CATEGORIES= devel python
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
MAINTAINER= yuri@FreeBSD.org
COMMENT= Python bindings for LLVM auto-generated from the LLVM-C API
LICENSE= MIT
RUN_DEPENDS= llvm-config${LLVM_VERSION}:devel/llvm${LLVM_VERSION} \
${PYTHON_PKGNAMEPREFIX}cffi>=1.0.0:devel/py-cffi@${FLAVOR}
USES= python
USE_GITHUB= yes
GH_ACCOUNT= revng
USE_PYTHON= distutils autoplist
NO_ARCH= yes
# LLVM_CONFIG environment variable overrides this: ex. LLVM_CONFIG=llvm-config40 changes to llvm40
LLVM_VERSION= 39 # README says: It has been tested with LLVM 3.4, 3.8 and 3.9
post-patch:
@${REINPLACE_CMD} -e 's|"llvm-config"|"llvm-config${LLVM_VERSION}"|' ${WRKSRC}/llvmcpy/llvm.py
.include <bsd.port.mk>

View File

@ -0,0 +1,3 @@
TIMESTAMP = 1515093939
SHA256 (revng-llvmcpy-v0.1.1-8-g6635c3a_GH0.tar.gz) = ed93211eebcabc6182869a9db756e8730d4f4c27fffc9dca6ab0908ed65fcd74
SIZE (revng-llvmcpy-v0.1.1-8-g6635c3a_GH0.tar.gz) = 11471

View File

@ -0,0 +1,7 @@
The main goal of llvmcpy is to provide Python bindings for the LLVM project
that are fast and require the lowest possible maintainance effort. To achive
this, we use CFFI to parse the (slightly adapted) header files for the LLVM-C
API and automatically generate a set of classes and functions to interact with
them in a Pythonic way.
WWW: https://github.com/revng/llvmcpy