aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile.am
blob: 1361e96feb7dd8f259660a337f60e5b7e5521a87 (plain)
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
AM_CPPFLAGS = -I$(srcdir)/include

lib_LTLIBRARIES = src/libibverbs.la

ACLOCAL_AMFLAGS = -I config
AM_CFLAGS = -g -Wall -fno-strict-aliasing

src_libibverbs_la_CFLAGS = $(AM_CFLAGS) -DIBV_CONFIG_DIR=\"$(sysconfdir)/libibverbs.d\" \
			   $(LIBNL_CFLAGS)
libibverbs_version_script = @LIBIBVERBS_VERSION_SCRIPT@
src_libibverbs_la_LIBADD = $(LIBNL_LIBS)

src_libibverbs_la_SOURCES = src/cmd.c src/compat-1_0.c src/device.c src/init.c \
			    src/marshall.c src/memory.c src/sysfs.c src/verbs.c \
			    src/enum_strs.c
if ! NO_RESOLVE_NEIGH
src_libibverbs_la_SOURCES += src/neigh.c
noinst_HEADERS = src/neigh.h src/nl1_compat.h
endif
src_libibverbs_la_LDFLAGS = -version-info 1 -export-dynamic \
    $(libibverbs_version_script)
src_libibverbs_la_DEPENDENCIES = $(srcdir)/src/libibverbs.map

bin_PROGRAMS = examples/ibv_devices examples/ibv_devinfo \
    examples/ibv_asyncwatch examples/ibv_rc_pingpong examples/ibv_uc_pingpong \
    examples/ibv_ud_pingpong examples/ibv_srq_pingpong examples/ibv_xsrq_pingpong
examples_ibv_devices_SOURCES = examples/device_list.c
examples_ibv_devices_LDADD = $(top_builddir)/src/libibverbs.la $(LIBNL_LIBS)
examples_ibv_devinfo_SOURCES = examples/devinfo.c
examples_ibv_devinfo_LDADD = $(top_builddir)/src/libibverbs.la $(LIBNL_LIBS)
examples_ibv_rc_pingpong_SOURCES = examples/rc_pingpong.c examples/pingpong.c
examples_ibv_rc_pingpong_LDADD = $(top_builddir)/src/libibverbs.la $(LIBNL_LIBS)
examples_ibv_uc_pingpong_SOURCES = examples/uc_pingpong.c examples/pingpong.c
examples_ibv_uc_pingpong_LDADD = $(top_builddir)/src/libibverbs.la $(LIBNL_LIBS)
examples_ibv_ud_pingpong_SOURCES = examples/ud_pingpong.c examples/pingpong.c
examples_ibv_ud_pingpong_LDADD = $(top_builddir)/src/libibverbs.la $(LIBNL_LIBS)
examples_ibv_srq_pingpong_SOURCES = examples/srq_pingpong.c examples/pingpong.c
examples_ibv_srq_pingpong_LDADD = $(top_builddir)/src/libibverbs.la $(LIBNL_LIBS)
examples_ibv_xsrq_pingpong_SOURCES = examples/xsrq_pingpong.c examples/pingpong.c
examples_ibv_xsrq_pingpong_LDADD = $(top_builddir)/src/libibverbs.la $(LIBNL_LIBS)
examples_ibv_asyncwatch_SOURCES = examples/asyncwatch.c
examples_ibv_asyncwatch_LDADD = $(top_builddir)/src/libibverbs.la $(LIBNL_LIBS)

libibverbsincludedir = $(includedir)/infiniband

libibverbsinclude_HEADERS = include/infiniband/arch.h include/infiniband/driver.h \
    include/infiniband/kern-abi.h include/infiniband/opcode.h include/infiniband/verbs.h \
    include/infiniband/sa-kern-abi.h include/infiniband/sa.h include/infiniband/marshall.h

man_MANS = man/ibv_asyncwatch.1 man/ibv_devices.1 man/ibv_devinfo.1	\
    man/ibv_rc_pingpong.1 man/ibv_uc_pingpong.1 man/ibv_ud_pingpong.1	\
    man/ibv_srq_pingpong.1 man/ibv_alloc_pd.3 man/ibv_attach_mcast.3	\
    man/ibv_create_ah.3 man/ibv_create_ah_from_wc.3			\
    man/ibv_create_comp_channel.3 man/ibv_create_cq.3			\
    man/ibv_create_qp.3 man/ibv_create_srq.3 man/ibv_event_type_str.3	\
    man/ibv_fork_init.3 man/ibv_get_async_event.3 man/ibv_create_flow.3 \
    man/ibv_get_cq_event.3 man/ibv_get_device_guid.3			\
    man/ibv_get_device_list.3 man/ibv_get_device_name.3			\
    man/ibv_modify_qp.3 man/ibv_modify_srq.3 man/ibv_open_device.3	\
    man/ibv_poll_cq.3 man/ibv_post_recv.3 man/ibv_post_send.3		\
    man/ibv_post_srq_recv.3 man/ibv_query_device.3 man/ibv_query_gid.3	\
    man/ibv_query_pkey.3 man/ibv_query_port.3 man/ibv_query_qp.3	\
    man/ibv_query_srq.3 man/ibv_rate_to_mult.3 man/ibv_reg_mr.3		\
    man/ibv_req_notify_cq.3 man/ibv_resize_cq.3 man/ibv_rate_to_mbps.3  \
    man/ibv_create_qp_ex.3 man/ibv_create_srq_ex.3 man/ibv_open_xrcd.3  \
    man/ibv_get_srq_num.3 man/ibv_open_qp.3 man/ibv_query_device_ex.3	\
    man/ibv_alloc_mw.3 man/ibv_bind_mw.3 man/ibv_inc_rkey.3		\
    man/ibv_rereg_mr.3 man/ibv_create_cq_ex.3				\
    man/ibv_query_rt_values_ex.3 man/ibv_xsrq_pingpong.1		\
    man/ibv_create_wq.3 man/ibv_modify_wq.3				\
    man/ibv_create_rwq_ind_table.3

DEBIAN = debian/changelog debian/compat debian/control debian/copyright \
    debian/ibverbs-utils.install debian/libibverbs1.install \
    debian/libibverbs1.postinst debian/libibverbs-dev.install \
    debian/rules

EXTRA_DIST = include/infiniband/driver.h include/infiniband/kern-abi.h \
    include/infiniband/opcode.h include/infiniband/verbs.h include/infiniband/marshall.h \
    include/infiniband/sa-kern-abi.h include/infiniband/sa.h \
    src/ibverbs.h examples/pingpong.h \
    src/libibverbs.map libibverbs.spec.in $(man_MANS)

dist-hook: libibverbs.spec
	cp libibverbs.spec $(distdir)

install-data-hook:
	cd $(DESTDIR)$(mandir)/man3 && \
	$(RM) ibv_ack_async_event.3 && \
	$(RM) ibv_ack_cq_events.3 && \
	$(RM) ibv_close_device.3 && \
	$(RM) ibv_dealloc_pd.3 && \
	$(RM) ibv_dereg_mr.3 && \
	$(RM) ibv_destroy_ah.3 && \
	$(RM) ibv_destroy_comp_channel.3 && \
	$(RM) ibv_destroy_cq.3 && \
	$(RM) ibv_destroy_qp.3 && \
	$(RM) ibv_destroy_srq.3 && \
	$(RM) ibv_detach_mcast.3 && \
	$(RM) ibv_free_device_list.3 && \
	$(RM) ibv_init_ah_from_wc.3 && \
	$(RM) mult_to_ibv_rate.3 && \
	$(RM) ibv_node_type_str.3 && \
	$(RM) ibv_port_state_str.3 && \
	$(RM) mbps_to_ibv_rate.3 && \
	$(RM) ibv_close_xrcd.3 && \
	$(RM) ibv_dealloc_mw.3 && \
	$(RM) ibv_destroy_flow.3 && \
	$(RM) ibv_destroy_wq.3 && \
	$(RM) ibv_destroy_rwq_ind_table.3 && \
	$(LN_S) ibv_get_async_event.3 ibv_ack_async_event.3 && \
	$(LN_S) ibv_get_cq_event.3 ibv_ack_cq_events.3 && \
	$(LN_S) ibv_open_device.3 ibv_close_device.3 && \
	$(LN_S) ibv_alloc_pd.3 ibv_dealloc_pd.3 && \
	$(LN_S) ibv_reg_mr.3 ibv_dereg_mr.3 && \
	$(LN_S) ibv_create_ah.3 ibv_destroy_ah.3 && \
	$(LN_S) ibv_create_comp_channel.3 ibv_destroy_comp_channel.3 && \
	$(LN_S) ibv_create_cq.3 ibv_destroy_cq.3 && \
	$(LN_S) ibv_create_qp.3 ibv_destroy_qp.3 && \
	$(LN_S) ibv_create_srq.3 ibv_destroy_srq.3 && \
	$(LN_S) ibv_attach_mcast.3 ibv_detach_mcast.3 && \
	$(LN_S) ibv_get_device_list.3 ibv_free_device_list.3 && \
	$(LN_S) ibv_create_ah_from_wc.3 ibv_init_ah_from_wc.3 && \
	$(LN_S) ibv_rate_to_mult.3 mult_to_ibv_rate.3 && \
	$(LN_S) ibv_event_type_str.3 ibv_node_type_str.3 && \
	$(LN_S) ibv_event_type_str.3 ibv_port_state_str.3 && \
	$(LN_S) ibv_rate_to_mbps.3 mbps_to_ibv_rate.3 && \
	$(LN_S) ibv_open_xrcd.3 ibv_close_xrcd.3 && \
	$(LN_S) ibv_alloc_mw.3 ibv_dealloc_mw.3 && \
	$(LN_S) ibv_create_flow.3 ibv_destroy_flow.3 && \
	$(LN_S) ibv_create_wq.3 ibv_destroy_wq.3 && \
	$(LN_S) ibv_create_rwq_ind_table.3 ibv_destroy_rwq_ind_table.3