2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL"), version 1.0.
4 # You may only use this file in accordance with the terms of version
7 # A full copy of the text of the CDDL should have accompanied this
8 # source. A copy of the CDDL is also available via the Internet at
9 # http://www.illumos.org/license/CDDL.
13 # Copyright 2014 Alexander Pyhalov. All rights reserved.
18 OBJS
=libbe_py_26.o libbe_py_27.o
19 TGTS
=libbe_py_26.so libbe_py_27.so
20 LIBS
=-lbe
-lnvpair
-lc
23 LDFLAGS
+= -Wl
,-M
$(MAPFILE
)
25 all: libbe_py_26.so libbe_py_27.so
27 libbe_py_26.so
: libbe_py_26.o
28 $(CC
) $(CFLAGS
) $(LDFLAGS
) -shared
$< -lpython2.6
$(LIBS
) -o
$@
30 libbe_py_27.so
: libbe_py_27.o
31 $(CC
) $(CFLAGS
) $(LDFLAGS
) -shared
$< -lpython2.7
$(LIBS
) -o
$@
33 libbe_py_26.o
: libbe_py.c Makefile
34 $(CC
) -c
$(CFLAGS
) libbe_py.c
-fPIC
-DPIC
-I
/usr
/include/python2.6
-o
$@
36 libbe_py_27.o
: libbe_py.c Makefile
37 $(CC
) -c
$(CFLAGS
) libbe_py.c
-fPIC
-DPIC
-I
/usr
/include/python2.7
-o
$@
40 rm -fr
$(OBJS
) $(TGTS
)
43 # Do nothing, files are picked from BUILD_DIR