1 # Top level -*- Makefile -*- for GHDL.
2 # Copyright (C) 2002 - 2014 Tristan Gingold
4 # This program is free software: you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation, either version 2 of the License, or
7 # (at your option) any later version.
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
14 # You should have received a copy of the GNU General Public License
15 # along with this program. If not, see <gnu.org/licenses>.
22 abs_srcdir
=@abs_srcdir@
28 libdirsuffix
=@libdirsuffix@
29 libghdldirsuffix
=@libghdldirsuffix@
30 incdirsuffix
=@incdirsuffix@
34 gcc_src_dir
=@gcc_src_dir@
35 LLVM_CONFIG
=@llvm_config@
37 LIBBACKTRACE
=@backtrace_lib@
39 build_mode
=@build_mode@
40 ghdl_version
=@ghdl_version@
41 libghdl_version
=@libghdl_version@
42 enable_werror
=@enable_werror@
43 enable_checks
=@enable_checks@
44 enable_gplcompat
=@enable_gplcompat@
45 enable_libghdl
=@enable_libghdl@
46 default_pic
=@default_pic@
47 with_sundials
=@with_sundials@
48 sundials_incflags
=@sundials_incflags@
49 sundials_ldflags
=@sundials_ldflags@
51 INSTALL_PROGRAM
=install -m
755
52 INSTALL_DATA
=install -m
644
57 libdir=$(prefix)/$(libdirsuffix
)
58 libghdldir
=$(prefix)/$(libghdldirsuffix
)
59 incdir
=$(prefix)/$(incdirsuffix
)/ghdl
68 VHDL_LIB_DIR
=$(prefix)/$(libghdldirsuffix
)
70 ifeq "$(enable_checks)" "true"
76 # Optimize + no checks
87 ifeq "$(build_mode)" "coverage"
88 COVERAGE_FLAGS
+=-fprofile-arcs
-ftest-coverage
91 # Warnings as errors. Comment this line if a warning looks not valid.
92 ifeq "$(enable_werror)" "true"
93 WARN_ADAFLAGS
+=-gnatwe
96 WARN_ADAFLAGS
+=-gnatwa
-gnatwC
-gnatf
98 GNATFLAGS
=-gnat12
-gnaty3befhkmr
$(OPT_FLAGS
) $(COVERAGE_FLAGS
) $(WARN_ADAFLAGS
) $(ADA_FLAGS
)
99 GRT_FLAGS
=$(COVERAGE_FLAGS
)
100 GRT_ADAFLAGS
:=$(OPT_FLAGS
) $(WARN_ADAFLAGS
) -gnatw.X
$(filter-out -gnata
,$(ADA_FLAGS
))
102 ifeq "$(default_pic)" "true"
103 GRT_FLAGS
+=$(PIC_FLAGS
)
108 CFLAGS
:=$(OPT_FLAGS
) $(WARN_CFLAGS
) $(CFLAGS
)
109 CXXFLAGS
:=$(OPT_FLAGS
) $(WARN_CFLAGS
) $(CXXFLAGS
)
114 #target=i686-pc-linux-gnu
115 #target=x86_64-pc-linux-gnu
116 #target=i686-apple-darwin
117 #target=x86_64-apple-darwin
118 #target=i386-pc-mingw32
121 SHLIB_FLAGS
=-Wl
,-soname
,$(notdir $@
)
122 else ifeq ($(SOEXT
),.dll
)
124 else ifeq ($(SOEXT
),.dylib
)
125 # Allow the use of -rpath in executable
126 SHLIB_FLAGS
=-Wl
,-install_name
,@rpath
/$(notdir $@
)
129 # Flags for libraries
130 LIBSRC_DIR
:=$(srcdir)/libraries
131 LIBDST_DIR
:=$(libghdldirsuffix
)
133 LIBVHDL_FLAGS_TO_PASS
=\
134 LIBSRC_DIR
="$(LIBSRC_DIR)" \
135 LIBDST_DIR
="$(LIBDST_DIR)" \
136 enable_gplcompat
="$(enable_gplcompat)" \
137 LN
="$(LN)" CP
="$(CP)" MKDIR
="$(MKDIR)"
139 # Object files from grt for the synthesis.
140 GRT_SYNTH_OBJS
=grt-cstdio.o grt-cdynload.o
142 all: Makefile
all.
$(backend
) all.libghdl
all.ghw
144 install: install.
$(backend
) install.vhdllib
install.vpi
install.libghdl
install.ghw
145 # Generate std.standard package VHDL source
146 "$(DESTDIR)$(bindir)/ghdl$(EXEEXT)" --disp-standard
--std
=87 > "$(DESTDIR)$(VHDL_LIB_DIR)/src/std/v87/standard.vhdl"
147 "$(DESTDIR)$(bindir)/ghdl$(EXEEXT)" --disp-standard
--std
=93 > "$(DESTDIR)$(VHDL_LIB_DIR)/src/std/v93/standard.vhdl"
148 "$(DESTDIR)$(bindir)/ghdl$(EXEEXT)" --disp-standard
--std
=08 > "$(DESTDIR)$(VHDL_LIB_DIR)/src/std/v08/standard.vhdl"
150 uninstall: uninstall.
$(backend
) uninstall.vhdllib
uninstall.vpi
uninstall.libghdl
uninstall.ghw
152 test: test.
$(backend
)
154 copy-sources
: copy-sources.
$(backend
)
156 libs
: libs.vhdl.
$(backend
)
158 .
/config.status
: $(srcdir)/configure
159 @if
[ -e
$@
]; then \
160 echo
"./config.status --reconfigure"; \
161 .
/config.status
--reconfigure
; \
163 echo
"config.status is lost, please configure manually" ; \
167 Makefile
: $(srcdir)/Makefile.in .
/config.status
170 setup.py
: $(srcdir)/setup.py.in .
/config.status
173 scripts
/gcc
/Make-lang.in
: $(srcdir)/scripts
/gcc
/Make-lang.in.in .
/config.status
176 GHDL_COMMON_INCFLAGS
=-aI
$(srcdir)/src
-aI
$(srcdir)/src
/vhdl
-aI
$(srcdir)/src
/verilog
-aI
$(srcdir)/src
/synth
-aI
$(srcdir)/src
/grt
-aI
$(srcdir)/src
/psl
-aI
$(srcdir)/src
/vhdl
/translate
178 GRTSRCDIR
=$(abs_srcdir
)/src
/grt
179 include $(srcdir)/src
/grt
/Makefile.inc
181 version.tmp
: $(srcdir)/src
/version.in
force
182 # Create version.tmp from version.in, using git date/hash, or envvars.
183 # The user is allowed to set GHDL_VER_DESC to override description.
187 if
test -d
$(srcdir)/.git
&& desc
=`cd $(srcdir); git describe --dirty --long`; then \
188 VER_DESC
=`echo $$desc | sed -e 's/\([^-]*-g\)/r\1/' -e 's/-/./g' -e 's/^v//g'`; \
189 VER_REF
=`cd $(srcdir); git rev-parse --abbrev-ref HEAD`; \
190 VER_HASH
=`cd $(srcdir); git rev-parse HEAD`; \
193 -e
"s#@VER@#$(ghdl_version)#" \
194 -e
"s#@DESC@#$${GHDL_VER_DESC:-$$VER_DESC}#" \
195 -e
"s#@REF@#$${GHDL_VER_REF:-$$VER_REF}#" \
196 -e
"s#@HASH@#$${GHDL_VER_HASH:-$$VER_HASH}#" \
199 version.ads
: version.tmp
200 # Change version.ads only if version.tmp has been modified to avoid
202 if
[ ! -r
$@
] ||
! cmp
$< $@
> /dev
/null
; then
$(CP
) $< $@
; fi
204 VPI_OBJS
=sys_display.o sys_finish.o sys_priv.o sys_time.o sys_fileio.o \
205 sys_scanf.o sys_random.o \
206 vpi_mcd.o vpip_format.o \
207 sys_readmem.o sys_readmem_lex.o \
209 vpi_debug.o sys_clog2.o sys_plusargs.o
211 VPI_PIC_OBJS
=$(foreach v
,$(VPI_OBJS
),pic
/$(v
))
213 VPI_CFLAGS
=-I
$(srcdir)/src
/verilog
-Wall
-std
=c99
$(CFLAGS
) -D_SVID_SOURCE
=1
214 VPI_CCOMPILE
=$(CC
) -c
-o
$@
$< -DGHDL
$(VPI_CFLAGS
)
215 VPI_CCOMPILE_PIC
=$(VPI_CCOMPILE
) $(PIC_FLAGS
)
217 sys_display.o
: $(srcdir)/src
/verilog
/vpi
/sys_display.c
220 pic
/sys_display.o
: $(srcdir)/src
/verilog
/vpi
/sys_display.c
223 sys_finish.o
: $(srcdir)/src
/verilog
/vpi
/sys_finish.c
226 pic
/sys_finish.o
: $(srcdir)/src
/verilog
/vpi
/sys_finish.c
229 sys_priv.o
: $(srcdir)/src
/verilog
/vpi
/sys_priv.c
232 pic
/sys_priv.o
: $(srcdir)/src
/verilog
/vpi
/sys_priv.c
235 sys_time.o
: $(srcdir)/src
/verilog
/vpi
/sys_time.c
238 pic
/sys_time.o
: $(srcdir)/src
/verilog
/vpi
/sys_time.c
241 vpi_mcd.o
: $(srcdir)/src
/verilog
/vpilib
/vpi_mcd.c
244 pic
/vpi_mcd.o
: $(srcdir)/src
/verilog
/vpilib
/vpi_mcd.c
247 sys_fileio.o
: $(srcdir)/src
/verilog
/vpi
/sys_fileio.c
250 pic
/sys_fileio.o
: $(srcdir)/src
/verilog
/vpi
/sys_fileio.c
253 sys_scanf.o
: $(srcdir)/src
/verilog
/vpi
/sys_scanf.c
256 pic
/sys_scanf.o
: $(srcdir)/src
/verilog
/vpi
/sys_scanf.c
259 sys_random.o
: $(srcdir)/src
/verilog
/vpi
/sys_random.c
262 pic
/sys_random.o
: $(srcdir)/src
/verilog
/vpi
/sys_random.c
265 vpip_format.o
: $(srcdir)/src
/verilog
/vpilib
/vpip_format.c
268 pic
/vpip_format.o
: $(srcdir)/src
/verilog
/vpilib
/vpip_format.c
271 sys_readmem.o
: $(srcdir)/src
/verilog
/vpi
/sys_readmem.c
274 pic
/sys_readmem.o
: $(srcdir)/src
/verilog
/vpi
/sys_readmem.c
277 sys_readmem_lex.o
: $(srcdir)/src
/verilog
/vpi
/sys_readmem_lex.c
280 pic
/sys_readmem_lex.o
: $(srcdir)/src
/verilog
/vpi
/sys_readmem_lex.c
283 v2009_bitvec.o
: $(srcdir)/src
/verilog
/vpi
/v2009_bitvec.c
286 pic
/v2009_bitvec.o
: $(srcdir)/src
/verilog
/vpi
/v2009_bitvec.c
289 vpi_debug.o
: $(srcdir)/src
/verilog
/vpi
/vpi_debug.c
292 pic
/vpi_debug.o
: $(srcdir)/src
/verilog
/vpi
/vpi_debug.c
295 sys_clog2.o
: $(srcdir)/src
/verilog
/vpi
/sys_clog2.c
298 pic
/sys_clog2.o
: $(srcdir)/src
/verilog
/vpi
/sys_clog2.c
301 sys_plusargs.o
: $(srcdir)/src
/verilog
/vpi
/sys_plusargs.c
304 pic
/sys_plusargs.o
: $(srcdir)/src
/verilog
/vpi
/sys_plusargs.c
307 #################### For mcode backend ##############################
309 all.mcode
: ghdl_mcode
$(EXEEXT
) libs.vhdl.mcode
all.vpi
311 GHDL_MCODE_INCFLAGS
=$(GHDL_COMMON_INCFLAGS
) -aI
$(srcdir)/src
/ghdldrv
-aI
$(srcdir)/src
/ortho
-aI
$(srcdir)/src
/ortho
/mcode
-aI
$(srcdir)/src
/synth
313 ghdl_mcode
$(EXEEXT
): GRT_FLAGS
+=-DWITH_GNAT_RUN_TIME
314 ghdl_mcode
$(EXEEXT
): $(GRT_ADD_OBJS
) $(GRT_SRC_DEPS
) $(ORTHO_DEPS
) $(VPI_OBJS
) \
315 memsegs_c.o chkstk.o version.ads
force
316 $(GNATMAKE
) -o
$@
-gnat12
$(GHDL_MCODE_INCFLAGS
) $(GNATFLAGS
) -gnatw.A ghdl_jit.adb
$(GNAT_BARGS
) -largs memsegs_c.o chkstk.o
$(GRT_ADD_OBJS
) $(LDFLAGS
) $(subst @
,$(GRTSRCDIR
),$(GRT_EXTRA_LIB
) $(GRT_EXEC_OPTS
)) $(VPI_OBJS
) $(sundials_ldflags
) -shared-libgcc
318 memsegs_c.o
: $(srcdir)/src
/ortho
/mcode
/memsegs_c.c
319 $(CC
) -c
$(COVERAGE_FLAGS
) $(CFLAGS
) -o
$@
$<
321 libs.vhdl.mcode
: ghdl_mcode
$(EXEEXT
)
322 $(MAKE
) -f
$(srcdir)/libraries
/Makefile.inc
$(LIBVHDL_FLAGS_TO_PASS
) GHDL
=$(PWD
)/ghdl_mcode
$(EXEEXT
) GHDL_FLAGS
="" VHDL_COPY_OBJS
=no vhdl.libs.
all
324 install.mcode.program
: install.dirs ghdl_mcode
$(EXEEXT
)
325 $(INSTALL_PROGRAM
) ghdl_mcode
$(EXEEXT
) "$(DESTDIR)$(bindir)/ghdl$(EXEEXT)"
327 uninstall.mcode.program
:
328 $(RM
) "$(DESTDIR)$(bindir)/ghdl$(EXEEXT)"
330 install.mcode
: install.mcode.program
install.vhdllib
332 install.mcode.deps.dll
:
333 for f in
$$($(PYTHON
) $(srcdir)/scripts
/win-dll.py ghdl_mcode
$(EXEEXT
)); do \
334 $(INSTALL_PROGRAM
) -p
$$f "$(DESTDIR)$(bindir)/"; \
337 uninstall.mcode
: uninstall.mcode.program
uninstall.vhdllib
339 test.mcode
: ghdl_mcode
$(EXEEXT
)
340 cd
$(srcdir)/testsuite
; GHDL
=$(CURDIR
)/ghdl_mcode
$(EXEEXT
) .
/testsuite.sh
342 oread-mcode
$(EXEEXT
): force
343 $(MAKE
) -f
$(srcdir)/src
/ortho
/mcode
/Makefile \
344 ortho_srcdir
=$(srcdir)/src
/ortho ortho_exec
=$@ \
345 GNATFLAGS
="-aI$(srcdir)/src/ortho/oread $(GNATFLAGS)" all
347 #################### For gcc backend ##############################
349 gcc_vhdl_dir
=$(gcc_src_dir
)/gcc
/vhdl
352 @echo
"For installing sources in gcc, do:"
353 @echo
"1) $(MAKE) copy-sources"
354 @echo
"2) configure, build and install gcc"
355 @echo
"3) $(MAKE) ghdllib"
356 @echo
"4) $(MAKE) install"
358 copy-sources.gcc
: version.ads scripts
/gcc
/Make-lang.in
359 $(RM
) -rf
$(gcc_vhdl_dir
)
360 $(MKDIR
) $(gcc_vhdl_dir
)
361 $(CP
) -p version.ads ghdlsynth_maybe.ads
$(gcc_vhdl_dir
)
362 $(CP
) -p grt-readline.ads
$(gcc_vhdl_dir
)
363 $(CP
) -p
$(srcdir)/src
/*.ad?
$(gcc_vhdl_dir
)
364 $(CP
) -p
$(srcdir)/src
/vhdl
/*.ad?
$(gcc_vhdl_dir
)
365 $(CP
) -p
$(srcdir)/src
/vhdl
/translate
/*.ad?
$(gcc_vhdl_dir
)
366 $(CP
) -p
$(srcdir)/src
/synth
/*.ad?
$(gcc_vhdl_dir
)
367 $(CP
) -p
$(srcdir)/src
/psl
/*.ad?
$(gcc_vhdl_dir
)
368 $(CP
) -p
$(srcdir)/src
/grt
/grt.ad?
$(gcc_vhdl_dir
)
369 $(CP
) -p
$(srcdir)/src
/grt
/grt-types.ads
$(gcc_vhdl_dir
)
370 $(CP
) -p
$(srcdir)/src
/grt
/grt-vhdl_types.ads
$(gcc_vhdl_dir
)
371 $(CP
) -p
$(srcdir)/src
/grt
/grt-c.ad?
$(gcc_vhdl_dir
)
372 $(CP
) -p
$(srcdir)/src
/grt
/grt-fcvt.ad?
$(gcc_vhdl_dir
)
373 $(CP
) -p
$(srcdir)/src
/grt
/grt-algos.ad?
$(gcc_vhdl_dir
)
374 $(CP
) -p
$(srcdir)/src
/grt
/grt-arith.ad?
$(gcc_vhdl_dir
)
375 $(CP
) -p
$(srcdir)/src
/grt
/grt-vstrings.ad?
$(gcc_vhdl_dir
)
376 $(CP
) -p
$(srcdir)/src
/grt
/grt-cstdio.c
$(gcc_vhdl_dir
)
377 $(CP
) -p
$(srcdir)/src
/grt
/grt-stdio.ad?
$(gcc_vhdl_dir
)
378 $(CP
) -p
$(srcdir)/src
/grt
/grt-table.ad?
$(gcc_vhdl_dir
)
379 $(CP
) -p
$(srcdir)/src
/grt
/grt-files_operations.ad?
$(gcc_vhdl_dir
)
380 $(CP
) -p
$(srcdir)/src
/grt
/grt-to_strings.ad?
$(gcc_vhdl_dir
)
381 $(CP
) -p
$(srcdir)/src
/grt
/grt-strings.ad?
$(gcc_vhdl_dir
)
382 $(CP
) -p
$(srcdir)/src
/grt
/grt-severity.ads
$(gcc_vhdl_dir
)
383 $(CP
) -p
$(srcdir)/src
/grt
/grt-readline_
*.ad?
$(gcc_vhdl_dir
)
384 $(CP
) -p
$(srcdir)/src
/grt
/grt-dynload.ad?
$(gcc_vhdl_dir
)
385 $(CP
) -p
$(srcdir)/src
/grt
/grt-cdynload.c
$(gcc_vhdl_dir
)
386 $(CP
) -p
$(srcdir)/src
/ortho
/*.ad?
$(gcc_vhdl_dir
)
387 $(CP
) -p
$(srcdir)/src
/ortho
/gcc
/*.ad?
$(gcc_vhdl_dir
)
388 $(CP
) -p
$(srcdir)/src
/ortho
/gcc
/*.c
$(gcc_vhdl_dir
)
389 $(CP
) -p
$(srcdir)/src
/ortho
/gcc
/*.opt
$(gcc_vhdl_dir
)
390 base_ver
=`cat $(gcc_src_dir)/gcc/BASE-VER`; \
392 4.9*) gcc_ortho_lang
=ortho-lang-49.c
;; \
393 5.
*) gcc_ortho_lang
=ortho-lang-5.c
;; \
394 6 |
6.
*) gcc_ortho_lang
=ortho-lang-6.c
;; \
395 7.
*) gcc_ortho_lang
=ortho-lang-7.c
;; \
396 8.
*) gcc_ortho_lang
=ortho-lang-8.c
;; \
397 9.
* |
10.
* |
11.
*) gcc_ortho_lang
=ortho-lang-9.c
;; \
398 12.
*) gcc_ortho_lang
=ortho-lang-9.c
;; \
399 *) echo
"Mismatch gcc version from $(gcc_src_dir)"; \
400 echo
"Need gcc version 4.9.x, 5.x to 12.x"; \
403 $(CP
) -p
$(srcdir)/src
/ortho
/gcc
/$$gcc_ortho_lang \
404 $(gcc_vhdl_dir
)/ortho-lang.c
405 $(CP
) -p
$(srcdir)/doc
/ghdl.texi
$(srcdir)/doc
/ghdl
.1 $(gcc_vhdl_dir
)
406 $(MKDIR
) $(gcc_vhdl_dir
)/ghdldrv
407 $(CP
) -pR
$(srcdir)/src
/ghdldrv
/*.ad?
$(gcc_vhdl_dir
)/ghdldrv
408 $(CP
) -p scripts
/gcc
/Make-lang.in
$(gcc_vhdl_dir
)
409 $(CP
) -p
$(srcdir)/scripts
/gcc
/config-lang.in
$(gcc_vhdl_dir
)
410 $(CP
) -p
$(srcdir)/scripts
/gcc
/lang-options.h
$(gcc_vhdl_dir
)
411 $(CP
) -p
$(srcdir)/scripts
/gcc
/lang-specs.h
$(gcc_vhdl_dir
)
412 # For gcc 12.x, use .cc extension
413 base_ver
=`cat $(gcc_src_dir)/gcc/BASE-VER`; \
415 12.
*) for f in
$(gcc_vhdl_dir
)/*.c
; do mv
$$f $${f}c
; done
; \
416 sed
-e
's/ortho-lang.c/ortho-lang.cc/' \
417 < $(srcdir)/scripts
/gcc
/config-lang.in \
418 > $(gcc_vhdl_dir
)/config-lang.in
;; \
421 # To build vhdl libs using a non-installed ghdl, define GHDL_GCC_BIN to the
422 # path of ghdl and GHDL1_GCC_BIN to path of ghdl1
423 GHDL_GCC_BIN
=$(DESTDIR
)$(bindir)/ghdl
$(EXEEXT
)
424 GHDL1_GCC_BIN
= # --GHDL1=/path/to/ghdl1
427 $(MAKE
) -f
$(srcdir)/libraries
/Makefile.inc
$(LIBVHDL_FLAGS_TO_PASS
) GHDL
="$(GHDL_GCC_BIN)" GHDL_FLAGS
="$(GHDL1_GCC_BIN) $(LIB_CFLAGS)" vhdl.libs.
all libs.vhdl.standard
429 ghdllib
: libs.vhdl.gcc
$(libghdldirsuffix
)/libgrt.a
all.libghdl
all.ghw
431 install.gcc
: install.grt
433 uninstall.gcc
: uninstall.grt
436 cd
$(srcdir)/testsuite
; GHDL
=$(GHDL_GCC_BIN
) GHWDUMP
=$(CURDIR
)/ghwdump
$(EXEEXT
) .
/testsuite.sh
438 #################### For gcc backend - development only (local build) ####
440 GHDL_GCC_INCFLAGS
=$(GHDL_COMMON_INCFLAGS
)
442 ghdl1-gcc
$(EXEEXT
): version.ads
$(GRT_SYNTH_OBJS
) force
443 $(MAKE
) -f
$(srcdir)/src
/ortho
/gcc
/Makefile \
444 ortho_srcdir
=$(srcdir)/src
/ortho ortho_exec
=$@ \
445 GNATLFLAGS
="$(GRT_SYNTH_OBJS)" \
446 GNATFLAGS
="$(GHDL_GCC_INCFLAGS) $(GNATFLAGS)" all
448 ghdl_gcc
$(EXEEXT
): version.ads
$(GRT_SYNTH_OBJS
) force
449 $(GNATMAKE
) $(GHDL_GCC_INCFLAGS
) -aI
$(srcdir)/src
/ghdldrv \
450 $(GNATFLAGS
) ghdl_gcc
$(GNAT_BARGS
) \
451 -largs
$(LDFLAGS
) $(GRT_SYNTH_OBJS
)
453 libs.vhdl.local_gcc
: ghdl_gcc
$(EXEEXT
) ghdl1-gcc
$(EXEEXT
)
454 $(MAKE
) -f
$(srcdir)/libraries
/Makefile.inc
$(LIBVHDL_FLAGS_TO_PASS
) GHDL
=$(PWD
)/ghdl_gcc
$(EXEEXT
) GHDL_FLAGS
="--GHDL1=$(PWD)/ghdl1-gcc$(EXEEXT) $(LIB_CFLAGS)" vhdl.libs.
all libs.vhdl.standard
456 ghdl1-debug
$(EXEEXT
): version.ads
$(GRT_SYNTH_OBJS
) force
457 $(MAKE
) -f
$(srcdir)/src
/ortho
/debug
/Makefile \
458 ortho_srcdir
=$(srcdir)/src
/ortho ortho_exec
=$@ \
459 GNATFLAGS
="$(GHDL_GCC_INCFLAGS) $(GNATFLAGS)" \
460 GNATLFLAGS
="$(GRT_SYNTH_OBJS)" \
461 GNATMAKE
="$(GNATMAKE)" all
463 oread-gcc
$(EXEEXT
): force
464 $(MAKE
) -f
$(srcdir)/src
/ortho
/gcc
/Makefile \
465 ortho_srcdir
=$(srcdir)/src
/ortho ortho_exec
=$@ \
466 GNATFLAGS
="-aI$(srcdir)/src/ortho/oread $(GNATFLAGS)" all
468 #################### For llvm backend ##############################
470 GHDL_LLVM_INCFLAGS
=$(GHDL_COMMON_INCFLAGS
) -aI
$(srcdir)/src
/ghdldrv
-aI
$(srcdir)/src
/ortho
-aI
$(srcdir)/src
/ortho
/$(llvm_be
) -aI
$(srcdir)/src
/synth
472 all.llvm
: ghdl1-llvm
$(EXEEXT
) ghdl_llvm
$(EXEEXT
) grt-all libs.vhdl.llvm
all.vpi
474 all.llvm_jit
: ghdl_llvm_jit
$(EXEEXT
)
476 ghdl_llvm_jit
$(EXEEXT
): GRT_FLAGS
+=-DWITH_GNAT_RUN_TIME
477 ghdl_llvm_jit
$(EXEEXT
): $(GRT_ADD_OBJS
) $(GRT_SRC_DEPS
) $(ORTHO_DEPS
) \
478 llvm-cbindings.o version.ads
force
479 $(GNATMAKE
) -o
$@
$(GHDL_LLVM_INCFLAGS
) $(GNATFLAGS
) ghdl_jit.adb \
480 $(GNAT_BARGS
) -largs llvm-cbindings.o
$(GRT_ADD_OBJS
) \
481 $(subst @
,$(GRTSRCDIR
),$(GRT_EXTRA_LIB
)) --LINK
=$(CXX
) \
482 `$(LLVM_CONFIG) --ldflags --libs --system-libs` $(LDFLAGS
)
484 llvm-cbindings.o
: $(srcdir)/src
/ortho
/$(llvm_be
)/llvm-cbindings.
cpp
485 $(CXX
) -c
`$(LLVM_CONFIG) --includedir --cxxflags` \
486 $(COVERAGE_FLAGS
) $(CXXFLAGS
) -o
$@
$<
488 libs.vhdl.llvmjit
: ghdl_llvm_jit
$(EXEEXT
)
489 $(MAKE
) -f
$(srcdir)/libraries
/Makefile.inc
$(LIBVHDL_FLAGS_TO_PASS
) GHDL
=$(PWD
)/ghdl_llvm
$(EXEEXT
) GHDL_FLAGS
="" VHDLLIBS_COPY_OBJS
=no vhdl.libs.
all
491 libs.vhdl.llvm
: ghdl_llvm
$(EXEEXT
) ghdl1-llvm
$(EXEEXT
)
492 $(MAKE
) -f
$(srcdir)/libraries
/Makefile.inc
$(LIBVHDL_FLAGS_TO_PASS
) GHDL
=$(PWD
)/ghdl_llvm
$(EXEEXT
) GHDL_FLAGS
="--GHDL1=$(PWD)/ghdl1-llvm$(EXEEXT) $(LIB_CFLAGS)" vhdl.libs.
all libs.vhdl.standard
494 libs.vhdl.debug-llvm
: ghdl_llvm
$(EXEEXT
) ghdl1-debug
$(EXEEXT
)
495 $(MAKE
) -f
$(srcdir)/libraries
/Makefile.inc
$(LIBVHDL_FLAGS_TO_PASS
) GHDL
=$(PWD
)/ghdl_llvm
$(EXEEXT
) GHDL_FLAGS
="--GHDL1=$(PWD)/ghdl1-debug$(EXEEXT) $(LIB_CFLAGS)" vhdl.libs.
all libs.vhdl.standard
497 ghdl_llvm
$(EXEEXT
): version.ads
$(GRT_SYNTH_OBJS
) force
498 $(GNATMAKE
) $(GHDL_LLVM_INCFLAGS
) \
499 -aI
$(srcdir)/src
/ghdldrv
$(GNATFLAGS
) \
500 ghdl_llvm
$(GNAT_BARGS
) \
501 -largs
$(LDFLAGS
) $(GRT_SYNTH_OBJS
)
503 ghdl1-llvm
$(EXEEXT
): version.ads
$(GRT_SYNTH_OBJS
) force
504 $(MAKE
) -f
$(srcdir)/src
/ortho
/$(llvm_be
)/Makefile \
505 ortho_srcdir
=$(srcdir)/src
/ortho ortho_exec
=$@ \
506 GNATFLAGS
="$(GHDL_LLVM_INCFLAGS) $(GNATFLAGS)" \
507 GNATLFLAGS
="$(GRT_SYNTH_OBJS)" \
508 LDFLAGS
="$(LDFLAGS)" \
509 LLVM_CONFIG
="$(LLVM_CONFIG)" CXX
="$(CXX)" \
510 CXXFLAGS
="$(COVERAGE_FLAGS) $(CXXFLAGS)" \
511 GNATMAKE
="$(GNATMAKE)" all
513 oread-llvm
$(EXEEXT
): force
514 $(MAKE
) -f
$(srcdir)/src
/ortho
/$(llvm_be
)/Makefile \
515 ortho_srcdir
=$(srcdir)/src
/ortho ortho_exec
=$@ \
516 GNATMAKE
="$(GNATMAKE)" \
517 GNATFLAGS
="-aI$(srcdir)/src/ortho/oread $(GNATFLAGS)" \
518 LLVM_CONFIG
="$(LLVM_CONFIG)" CXX
="$(CXX)"
520 install.llvm.program
: install.dirs ghdl1-llvm
$(EXEEXT
) ghdl_llvm
$(EXEEXT
)
521 $(INSTALL_PROGRAM
) ghdl_llvm
$(EXEEXT
) $(DESTDIR
)$(bindir)/ghdl
$(EXEEXT
)
522 $(INSTALL_PROGRAM
) ghdl1-llvm
$(EXEEXT
) $(DESTDIR
)$(bindir)/ghdl1-llvm
$(EXEEXT
)
524 test.llvm
: ghdl_llvm
$(EXEEXT
)
525 cd
$(srcdir)/testsuite
; GHDL
=$(CURDIR
)/ghdl_llvm
$(EXEEXT
) .
/testsuite.sh
527 uninstall.llvm.program
:
528 $(RM
) $(DESTDIR
)$(bindir)/ghdl1-llvm
$(EXEEXT
)
529 $(RM
) $(DESTDIR
)$(bindir)/ghdl
$(EXEEXT
)
531 install.llvm
: install.llvm.program
install.grt
533 uninstall.llvm
: uninstall.llvm.program
uninstall.grt
535 ################ For simul (no code generation, interpretation) ##########
537 GHDL_SIMUL_INCFLAGS
=$(GHDL_COMMON_INCFLAGS
) -aI
$(srcdir)/src
/ghdldrv
-aI
$(srcdir)/src
/simul
-aI
$(srcdir)/src
/synth
539 GRT_SIMUL_OBJS
=$(GRT_C_OBJS
) grt-cdynload.o
541 ghdl_simul
$(EXEEXT
): GRT_FLAGS
+=-DWITH_GNAT_RUN_TIME
542 ghdl_simul
$(EXEEXT
): $(GRT_SIMUL_OBJS
) $(GRT_SRC_DEPS
) version.ads
force
543 $(GNATMAKE
) $(GHDL_SIMUL_INCFLAGS
) $(GNATFLAGS
) -gnat12 ghdl_simul
$(GNAT_BARGS
) -largs
$(LDFLAGS
) $(GRT_SIMUL_OBJS
) $(subst @
,$(GRTSRCDIR
),$(GRT_EXTRA_LIB
)) $(sundials_ldflags
)
545 libs.vhdl.simul
: ghdl_simul
$(EXEEXT
)
546 $(MAKE
) -f
$(srcdir)/libraries
/Makefile.inc
$(LIBVHDL_FLAGS_TO_PASS
) GHDL
=$(PWD
)/ghdl_simul
$(EXEEXT
) GHDL_FLAGS
="" VHDLLIBS_COPY_OBJS
=no vhdl.libs.
all
548 install.simul.program
: install.dirs ghdl_simul
$(EXEEXT
)
549 $(INSTALL_PROGRAM
) ghdl_simul
$(EXEEXT
) $(DESTDIR
)$(bindir)/ghdl
$(EXEEXT
)
551 uninstall.simul.program
:
552 $(RM
) $(DESTDIR
)$(bindir)/ghdl
$(EXEEXT
)
554 install.simul
: install.simul.program
556 uninstall.simul
: uninstall.simul.program
559 ################ libghdl (library for the vhdl part) ####################
561 LIBGHDL_INCFLAGS
=$(GHDL_COMMON_INCFLAGS
) -aI
$(srcdir)/src
/synth
-aI
$(srcdir)/src
/vhdl
/libghdl
-aI
$(srcdir)/src
/ghdldrv
563 libghdl_name
=libghdl-
$(libghdl_version
)$(SOEXT
)
565 LIBGHDL_GRT_OBJS
= pic
/grt-cstdio.o pic
/grt-cdynload.o
$(VPI_PIC_OBJS
)
567 lib
/$(libghdl_name
): $(GRT_SRC_DEPS
) $(LIBGHDL_GRT_OBJS
) version.ads
force
568 # Use -g for gnatlink so that the binder file is not removed. We need
570 $(GNATMAKE
) -I-
-aI.
-D pic
-z libghdl
-o
$@
-gnat12
$(GNATFLAGS
) $(PIC_FLAGS
) $(LIBGHDL_INCFLAGS
) -bargs
-shared
-Llibghdl_
-largs
-g
-shared
$(SHLIB_FLAGS
) $(filter-out -static
,$(LDFLAGS
)) $(LIBGHDL_GRT_OBJS
)
571 # On windows, gnatmake (via Osint.Executable_Name) always appends .exe
572 # Adjust. (Other solution: use gnatmake for compilation and binding,
573 # then use gnatlink directly for linking).
575 -mv lib
/$(libghdl_name
).exe
$@
578 libghdl.a
: lib
/$(libghdl_name
)
579 # Also create a static library
580 sed
-e
'1,/-- BEGIN/d' -e
'/-- END/,$$d' -e
's/^ -- //' < b~libghdl.adb
> libghdl.bind
582 ar rc
$@ b~libghdl.o
$(LIBGHDL_GRT_OBJS
) `sed -e /^-/d < libghdl.bind`
583 grep adalib libghdl.bind | sed
-e
's/^-L//' -e
's@adalib/@adalib/libgnat.a@' > libghdl.link
585 $(srcdir)/src
/synth
/include/synth_gates.h
: $(srcdir)/src
/synth
/netlists.ads
$(srcdir)/src
/synth
/netlists-gates.ads
586 echo
"/* DO NOT MODIFY" > $@
587 echo
" This file is automatically generated by Makefile. */" >> $@
588 echo
"enum Module_Id {" >> $@
589 grep
-h
"constant Module_Id :=" $^ | sed
-e
'/constant Module_Id :=/s/:.*://' -e
's/;/,/' -e
's/ *--.*//' >> $@
592 echo
"enum Param_Type {" >> $@
593 grep
' Param_' $(srcdir)/src
/synth
/netlists.ads
>> $@
596 all.libghdl.true
: lib
/$(libghdl_name
) libghdl.a
598 all.libghdl
: all.libghdl.
$(enable_libghdl
)
600 install.libghdl.
include: install.dirs
$(srcdir)/src
/synth
/include/synth_gates.h
601 $(INSTALL_DATA
) -p
$(srcdir)/src
/synth
/include/synth.h
"$(DESTDIR)$(incdir)/"
602 $(INSTALL_DATA
) -p
$(srcdir)/src
/synth
/include/synth_gates.h
"$(DESTDIR)$(incdir)/"
604 test.
$(backend
): install.libghdl.local
605 install.libghdl.local
: all.libghdl
$(srcdir)/src
/synth
/include/synth_gates.h
606 $(MKDIR
) -p
$(incdirsuffix
)/ghdl
/
607 $(INSTALL_DATA
) -p
$(srcdir)/src
/synth
/include/synth.h
$(incdirsuffix
)/ghdl
/
608 $(INSTALL_DATA
) -p
$(srcdir)/src
/synth
/include/synth_gates.h
$(incdirsuffix
)/ghdl
/
611 $(INSTALL_PROGRAM
) -p lib
/$(libghdl_name
) "$(DESTDIR)$(libdir)/"
612 $(INSTALL_PROGRAM
) -p libghdl.a
"$(DESTDIR)$(libdir)/"
613 $(INSTALL_DATA
) -p libghdl.link
"$(DESTDIR)$(libdir)/"
615 install.libghdl.true
: install.libghdl.lib
install.libghdl.
include
617 install.libghdl.false
:
618 install.libghdl
: install.libghdl.
$(enable_libghdl
)
620 copy.libghdl.deps.dll
:
622 ldd lib
/$(libghdl_name
)
623 # Set IFS to handle CR-LF end of lines
625 for f in
$$($(PYTHON
) $(srcdir)/scripts
/win-dll.py lib
/$(libghdl_name
)); do\
626 $(INSTALL_PROGRAM
) -p
$$f "bin/"; \
629 copy.libghdl.deps.dylib
:
630 copy.libghdl.deps.so
:
633 $(RM
) $(DESTDIR
)$(libdir)/$(libghdl_name
)
636 [ -d pythonb
] ||
$(MKDIR
) pythonb
637 $(CP
) -r
$(srcdir)/pyGHDL
/libghdl
$(srcdir)/setup.py pythonb
638 tar -zcvf
$@
-C pythonb .
640 ################ ghwdump #################################################
642 GHWDUMP_OBJS
=ghwdump.o libghw.o
644 ghwdump
$(EXEEXT
): $(GHWDUMP_OBJS
)
645 $(CC
) $(LDFLAGS
) -o
$@
$(GHWDUMP_OBJS
)
647 lib
/libghw
$(SOEXT
): libghw.o
648 $(CC
) $(PIC_FLAGS
) $(LDFLAGS
) -shared
-o
$@
$^
650 ghwdump.o
: $(srcdir)/ghw
/ghwdump.c
$(srcdir)/ghw
/libghw.h
651 $(CC
) -c
-o
$@
$< $(COVERAGE_FLAGS
) $(CFLAGS
)
653 libghw.o
: $(srcdir)/ghw
/libghw.c
$(srcdir)/ghw
/libghw.h
654 $(CC
) $(PIC_FLAGS
) -c
-o
$@
$< $(COVERAGE_FLAGS
) $(CFLAGS
)
656 all.ghw
: ghwdump
$(EXEEXT
) lib
/libghw
$(SOEXT
)
659 $(INSTALL_PROGRAM
) -p ghwdump
$(EXEEXT
) "$(DESTDIR)$(bindir)/"
660 $(INSTALL_PROGRAM
) -p lib
/libghw
$(SOEXT
) "$(DESTDIR)$(libdir)/"
661 $(INSTALL_DATA
) -p
$(srcdir)/ghw
/libghw.h
"$(DESTDIR)$(incdir)/"
664 $(RM
) "$(DESTDIR)$(bindir)/ghwdump$(EXEEXT)"
665 $(RM
) "$(DESTDIR)$(libdir)/libghw$(EXEEXT)"
666 $(RM
) "$(DESTDIR)$(incdir)/libghw.h"
668 ############### grt #####################################################
671 $(libghdldirsuffix
)/libgrt.a \
672 $(libghdldirsuffix
)/grt.lst \
673 $(libghdldirsuffix
)/grt-exec.lst \
674 $(libghdldirsuffix
)/grt-shared.lst \
676 $(INSTALL_DATA
) $(libghdldirsuffix
)/libgrt.a
$(DESTDIR
)$(VHDL_LIB_DIR
)/libgrt.a
677 $(INSTALL_DATA
) $(libghdldirsuffix
)/grt.lst
$(DESTDIR
)$(VHDL_LIB_DIR
)/grt.lst
678 $(INSTALL_DATA
) $(libghdldirsuffix
)/grt-exec.lst
$(DESTDIR
)$(VHDL_LIB_DIR
)/grt-exec.lst
679 $(INSTALL_DATA
) $(libghdldirsuffix
)/grt-shared.lst
$(DESTDIR
)$(VHDL_LIB_DIR
)/grt-shared.lst
680 $(INSTALL_DATA
) $(GRTSRCDIR
)/grt.ver
$(DESTDIR
)$(VHDL_LIB_DIR
)/grt.ver
681 test "x$(LIBBACKTRACE)" = x ||
test "x$(backend)" = xgcc || \
682 $(INSTALL_DATA
) $(LIBBACKTRACE
) $(DESTDIR
)$(VHDL_LIB_DIR
)/libbacktrace.a
685 $(RM
) $(DESTDIR
)$(VHDL_LIB_DIR
)/libgrt.a
686 $(RM
) $(DESTDIR
)$(VHDL_LIB_DIR
)/grt.lst
687 $(RM
) $(DESTDIR
)$(VHDL_LIB_DIR
)/grt-exec.lst
688 $(RM
) $(DESTDIR
)$(VHDL_LIB_DIR
)/grt-shared.lst
689 $(RM
) $(DESTDIR
)$(VHDL_LIB_DIR
)/grt.ver
690 $(RM
) $(DESTDIR
)$(VHDL_LIB_DIR
)/libbacktrace.a
692 ################ VPI #####################################################
694 vpi_thunk.o
: $(GRTSRCDIR
)/vpi_thunk.c
$(GRTSRCDIR
)/vpi_thunk.h
695 $(CC
) -c
-o
$@
$< $(PIC_FLAGS
) $(CFLAGS
)
697 vhpi_thunk.o
: $(GRTSRCDIR
)/vhpi_thunk.c
$(GRTSRCDIR
)/vhpi_thunk.h
698 $(CC
) -c
-o
$@
$< $(PIC_FLAGS
) $(CFLAGS
)
700 $(libdirsuffix
)/libghdlvpi
$(SOEXT
): vpi_thunk.o vhpi_thunk.o
701 $(MKDIR
) -p
$(libdirsuffix
)
702 $(CC
) $(SHLIB_FLAGS
) $(LDFLAGS
) -shared
-o
$@
$^
704 all.vpi
: $(libdirsuffix
)/libghdlvpi
$(SOEXT
)
706 install.vpi
: all.vpi
install.dirs
707 $(INSTALL_PROGRAM
) -p
$(libdirsuffix
)/libghdlvpi
$(SOEXT
) "$(DESTDIR)$(libdir)/"
708 $(INSTALL_DATA
) -p
$(GRTSRCDIR
)/vpi_user.h
"$(DESTDIR)$(incdir)/"
709 $(INSTALL_DATA
) -p
$(GRTSRCDIR
)/vhpi_user.h
"$(DESTDIR)$(incdir)/"
712 $(RM
) -f
"$(DESTDIR)$(libdir)/libghdlvpi$(SOEXT)"
713 $(RM
) -f
"$(DESTDIR)$(incdir)/vpi_user.h"
714 $(RM
) -f
"$(DESTDIR)$(incdir)/vhpi_user.h"
716 test.
$(backend
): install.vpi.local
717 install.vpi.local
: all.vpi
718 $(MKDIR
) -p
$(incdirsuffix
)/ghdl
/
719 $(INSTALL_DATA
) -p
$(GRTSRCDIR
)/vpi_user.h
$(incdirsuffix
)/ghdl
/
720 $(INSTALL_DATA
) -p
$(GRTSRCDIR
)/vhpi_user.h
$(incdirsuffix
)/ghdl
/
722 ################ Libraries ###############################################
743 ifeq ($(enable_gplcompat
),false
)
744 VHDLLIB_SUBDIRS
+=src
/vital95 src
/vital2000
748 # Use -p to create parents and to avoid error if existing.
749 $(MKDIR
) -p
"$(DESTDIR)$(prefix)"
750 $(MKDIR
) -p
"$(DESTDIR)$(bindir)"
751 $(MKDIR
) -p
"$(DESTDIR)$(libdir)"
752 $(MKDIR
) -p
"$(DESTDIR)$(libghdldir)"
753 $(MKDIR
) -p
"$(DESTDIR)$(incdir)"
755 install.vhdllib
: install.dirs
756 # Libraries (only if not empty)
757 for d in
$(VHDLLIB_SUBDIRS
); do \
758 $(MKDIR
) -p
"$(DESTDIR)$(VHDL_LIB_DIR)/$$d"; \
760 $(LIBDST_DIR
)/$$d/* "$(DESTDIR)$(VHDL_LIB_DIR)/$$d"; \
764 $(srcdir)/scripts
/ansi_color.sh
"$(DESTDIR)$(VHDL_LIB_DIR)/";
766 $(MKDIR
) -p
"$(DESTDIR)$(VHDL_LIB_DIR)/vendors"
768 $(srcdir)/scripts
/vendors
/* "$(DESTDIR)$(VHDL_LIB_DIR)/vendors/"
769 $(INSTALL_PROGRAM
) -p \
770 $(srcdir)/scripts
/vendors
/*.sh
"$(DESTDIR)$(VHDL_LIB_DIR)/vendors/"
773 $(RM
) -rf
$(DESTDIR
)$(VHDL_LIB_DIR
)
775 ####################### pyGHDL standalone ################################
777 setup-standalone.py
: $(srcdir)/setup-standalone.in
779 sed
-n
-e
'1,/^#@__init__/p' < $<; \
780 sed
-n
-e
'/__author__/,/^$$/p' < $(srcdir)/pyGHDL
/__init__.py
; \
781 echo
'srcdir = "$(srcdir)"' ; \
782 echo
'soext = "$(SOEXT)"'; \
783 sed
-n
-e
'/^#@__init__/,$$p' < $< ; \
786 python-wheel
: setup-standalone.py lib
/$(libghdl_name
) libs copy.libghdl.deps
$(SOEXT
)
790 $(CP
) -Rp
$(srcdir)/pyGHDL dist-wheel
/
792 for d in
$(VHDLLIB_SUBDIRS
); do \
793 $(MKDIR
) -p dist-wheel
/pyGHDL
/lib
/ghdl
/$$d; \
795 $(LIBDST_DIR
)/$$d/* dist-wheel
/pyGHDL
/lib
/ghdl
/$$d; \
798 $(INSTALL_PROGRAM
) -p lib
/$(libghdl_name
) dist-wheel
/pyGHDL
/lib
/
800 if ls bin
/lib
*.dll
2> /dev
/null
; then \
801 $(MKDIR
) -p dist-wheel
/pyGHDL
/bin
; \
802 $(INSTALL_PROGRAM
) -p bin
/lib
*.dll dist-wheel
/pyGHDL
/bin
; \
805 ####################### clean ############################################
808 $(RM
) -f
*.o
*.ali b~
*.ad?
*~
*.d b__
*.ad?
*.a
*.so
*.deps
*.bexch version.
* *.dll
*.dylib
809 $(RM
) -f ghdl_gcc
$(EXEEXT
) ghdl_mcode
$(EXEEXT
) ghdl
$(EXEEXT
) ghdl_llvm
$(EXEEXT
) ghdl_llvm_jit
$(EXEEXT
) ghdl_simul
$(EXEEXT
)
810 $(RM
) -f ghdl1-gcc
$(EXEEXT
) ghdl1-llvm
$(EXEEXT
) ghdl1-debug
$(EXEEXT
)
811 $(RM
) -f grt
/run-bind.ad? grt.lst grt
/grt-files grt
/grt-files.in
812 $(RM
) -f grt
/*.o grt
/*.ali
817 $(RM
) -f default_paths.ads ortho_code-x86-flags.ads
818 $(RM
) -f elf_arch.ads ghdlsynth_maybe.ads
819 $(RM
) -f grt
/grt-backtrace-impl.ads
820 $(RM
) -f Makefile config.status ghdl.gpr
823 $(RM
) -f memsegs_c.o chkstk.o chkstk-x64.o jumps.o times.o
824 $(RM
) -f grt-cstdio.o grt-cgnatrts.o grt-modules.o
825 $(RM
) -f grt-cvpi.o grt-cvhpi.o grt-cdynload.o
826 $(RM
) -f fstapi.o fastlz.o lz4.o
827 $(RM
) -f pic
/times.o pic
/grt-cvpi.o pic
/grt-cvhpi.o pic
/jumps.o
828 $(RM
) -f pic
/grt-cstdio.o pic
/grt-cgnatrts.o pic
/grt-modules.o
829 $(RM
) -f pic
/grt-cdynload.o
832 for d in
$(VHDLLIB_SUBDIRS
); do \
833 $(MKDIR
) -p
$(LIBDST_DIR
)/$$d; \
836 # Remove non GPL compatible source files
838 # Vital libraries aren't GPL compatible
839 $(RM
) -rf libraries
/vital95 libraries
/vital2000
840 # The GNA testsuite contains open-source reproducer that may not be GPL.
841 $(RM
) -rf testsuite
/gna
845 .PHONY
: force clean distclean clean-c clean-pure-gpl
847 # Most of the compilation is done through gnatmake, so using make -jX it not
849 # Hint: for parallel build use: make GNATMAKE="gnatmake -j8"
850 # Parallel builds may fail with the llvm backend as it can start two gnatmake
851 # in parallel: one for ghdl_llvm and the other for ghdl1-llvm. But they
852 # share the same objects.
853 # Any better fix is welcome!