Files
uwsgi/plugins/mono/uwsgiplugin.py
T
Ventero 08e1cf211c Fix symbol lookup error in the Mono plugin on OS X.
On OS X, mono libraries have to link against the Foundation framework.
2014-08-14 21:35:39 +02:00

18 lines
595 B
Python

import os
NAME='mono'
CFLAGS = os.popen('pkg-config --cflags mono-2').read().rstrip().split()
LDFLAGS = []
LIBS = os.popen('pkg-config --libs mono-2').read().rstrip().split()
GCC_LIST = ['mono_plugin']
if os.uname()[0] == 'Darwin':
LIBS.append('-framework Foundation')
def post_build(config):
if os.system("sn -k plugins/mono/uwsgi.key") != 0:
os._exit(1)
if os.system("mcs /target:library /r:System.Web.dll /keyfile:plugins/mono/uwsgi.key plugins/mono/uwsgi.cs") != 0:
os._exit(1)
print("*** uwsgi.dll available in %s/plugins/mono/uwsgi.dll ***" % os.getcwd())