File: Makefile.am

package info (click to toggle)
primesieve 5.7.2+ds-2
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 1,064 kB
  • ctags: 1,079
  • sloc: cpp: 5,871; makefile: 232; ansic: 176; sh: 102
file content (185 lines) | stat: -rw-r--r-- 5,165 bytes parent folder | download
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
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
AM_CPPFLAGS = -I$(top_srcdir)/include

lib_LTLIBRARIES = libprimesieve.la
libprimesieve_la_CXXFLAGS = $(OPENMP_CXXFLAGS)
libprimesieve_la_LDFLAGS = -version-info $(primesieve_lib_version)

if FORCE_SHARED_LIBRARY
libprimesieve_la_LDFLAGS += -no-undefined 
endif

bin_PROGRAMS = primesieve
primesieve_LDADD = libprimesieve.la

include_HEADERS = \
	include/primesieve.hpp \
	include/primesieve.h

otherincludedir = $(includedir)/primesieve
otherinclude_HEADERS = \
	include/primesieve/Callback.hpp \
	include/primesieve/cancel_callback.hpp \
	include/primesieve/iterator.hpp \
	include/primesieve/ParallelPrimeSieve.hpp \
	include/primesieve/primesieve_error.hpp \
	include/primesieve/PrimeSieve.hpp \
	include/primesieve/primesieve_iterator.h \
	include/primesieve/PushBackPrimes.hpp

EXTRA_DIST = \
	autogen.sh \
	README.md \
	RELEASE.md \
	Makefile.msvc \
	doc/Doxyfile.in \
	doc/primesieve.1 \
	doc/README.md \
	doc/mainpage.dox \
	examples/README.md \
	scripts/update_version.sh \
	src/apps/gui \
	src/msvc_compat \
	src/primesieve/README

DISTCLEANFILES = \
	doc/Doxyfile

man_MANS = \
	primesieve.1

libprimesieve_la_SOURCES = \
	src/primesieve/EratBig.cpp \
	src/primesieve/EratMedium.cpp \
	src/primesieve/EratSmall.cpp \
	src/primesieve/ParallelPrimeSieve.cpp \
	src/primesieve/popcount.cpp \
	src/primesieve/PreSieve.cpp \
	src/primesieve/PrimeFinder.cpp \
	src/primesieve/PrimeGenerator.cpp \
	src/primesieve/iterator.cpp \
	src/primesieve/primesieve_iterator.cpp \
	src/primesieve/primesieve_test.cpp \
	src/primesieve/PrimeSieve-nthPrime.cpp \
	src/primesieve/PrimeSieve.cpp \
	src/primesieve/primesieve-api.cpp \
	src/primesieve/primesieve-api-c.cpp \
	src/primesieve/SieveOfEratosthenes.cpp \
	src/primesieve/WheelFactorization.cpp \
	include/primesieve/bits.hpp \
	include/primesieve/callback_t.hpp \
	include/primesieve/config.hpp \
	include/primesieve/EratBig.hpp \
	include/primesieve/EratMedium.hpp \
	include/primesieve/EratSmall.hpp \
	include/primesieve/malloc_vector.hpp \
	include/primesieve/pmath.hpp \
	include/primesieve/littleendian_cast.hpp \
	include/primesieve/ParallelPrimeSieve-lock.hpp \
	include/primesieve/PreSieve.hpp \
	include/primesieve/PrimeFinder.hpp \
	include/primesieve/PrimeGenerator.hpp \
	include/primesieve/PrimeSieve-lock.hpp \
	include/primesieve/SieveOfEratosthenes.hpp \
	include/primesieve/SieveOfEratosthenes-inline.hpp \
	include/primesieve/toString.hpp \
	include/primesieve/WheelFactorization.hpp

primesieve_SOURCES = \
	src/apps/console/main.cpp \
	src/apps/console/help.cpp \
	src/apps/console/cmdoptions.cpp \
	src/apps/console/cmdoptions.hpp \
	src/apps/console/calculator.hpp

check: all
	./primesieve --test

# If installation directory is /usr/local/lib
# execute ldconfig after installation
install-exec-hook:
	test "$(prefix)" = "/usr/local" && command -v ldconfig 2>/dev/null && ldconfig /usr/local/lib 2>/dev/null || true

if MAKE_EXAMPLES
noinst_PROGRAMS = callback_cancel
callback_cancel_LDADD = libprimesieve.la
callback_cancel_SOURCES = examples/cpp/callback_cancel.cpp

noinst_PROGRAMS += callback_primes
callback_primes_LDADD = libprimesieve.la
callback_primes_SOURCES = examples/cpp/callback_primes.cpp

noinst_PROGRAMS += callback_primes_oop
callback_primes_oop_LDADD = libprimesieve.la
callback_primes_oop_SOURCES = examples/cpp/callback_primes_oop.cpp

noinst_PROGRAMS += count_primes
count_primes_LDADD = libprimesieve.la
count_primes_SOURCES = examples/cpp/count_primes.cpp

noinst_PROGRAMS += primesieve_iterator
primesieve_iterator_LDADD = libprimesieve.la
primesieve_iterator_SOURCES = examples/cpp/primesieve_iterator.cpp

noinst_PROGRAMS += nth_prime
nth_prime_LDADD = libprimesieve.la
nth_prime_SOURCES = examples/cpp/nth_prime.cpp

noinst_PROGRAMS += previous_prime
previous_prime_LDADD = libprimesieve.la
previous_prime_SOURCES = examples/cpp/previous_prime.cpp

noinst_PROGRAMS += store_primes_in_vector
store_primes_in_vector_LDADD = libprimesieve.la
store_primes_in_vector_SOURCES = examples/cpp/store_primes_in_vector.cpp

noinst_PROGRAMS += count_primes_c
count_primes_c_LDADD = libprimesieve.la
count_primes_c_SOURCES = examples/c/count_primes.c

noinst_PROGRAMS += previous_prime_c
previous_prime_c_LDADD = libprimesieve.la
previous_prime_c_SOURCES = examples/c/previous_prime.c

noinst_PROGRAMS += primesieve_iterator_c
primesieve_iterator_c_LDADD = libprimesieve.la
primesieve_iterator_c_SOURCES = examples/c/primesieve_iterator.c

noinst_PROGRAMS += nth_prime_c
nth_prime_c_LDADD = libprimesieve.la
nth_prime_c_SOURCES = examples/c/nth_prime.c

noinst_PROGRAMS += store_primes_in_array_c
store_primes_in_array_c_LDADD = libprimesieve.la
store_primes_in_array_c_SOURCES = examples/c/store_primes_in_array.c
endif

pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = primesieve.pc

if HAVE_DOXYGEN
doxygen:
	cd doc && $(DOXYGEN)
endif

if MAINTAINER_MODE
if HAVE_HELP2MAN

H2MFLAGS = \
	--manual="primesieve" \
	--source="primesieve (Debian $(DEB_PKG_VERSION))" \
	--locale=C.UTF-8 \
	--libtool \
	--no-info

primesieve.1: primesieve
	$(HELP2MAN) \
			-s 1 \
			$(H2MFLAGS) \
			-n "efficient prime number generator" \
			-o $@ \
		./$<

endif
endif

doc: $(DOXYGEN)