forked from eclipse-omr/omr
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The initial set of components in the OMR project include: port: platform porting library thread: a cross platform pthread-like threading library util: general utilities useful for building cross platform runtimes omrsigcompat: signal handling compatibility library omrtrace: tracing library for communication with IBM Health Center monitoring tools tool: code generation tools for the build system gc: garbage collection framework for managed heaps vm: APIs to manage per-interpreter and per-thread contexts example: demonstration code to show how a language runtime might consume some OMR components fvtest: a language-independent test framework so that OMR components can be tested outside of a language runtime CQs: 11033, 11034, 11035 Signed-off-by: Charlie Gracie <[email protected]>
- Loading branch information
1 parent
a3cb717
commit b3c44ed
Showing
1,277 changed files
with
414,740 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,254 @@ | ||
############################################################################### | ||
# | ||
# (c) Copyright IBM Corp. 2015, 2016 | ||
# | ||
# This program and the accompanying materials are made available | ||
# under the terms of the Eclipse Public License v1.0 and | ||
# Apache License v2.0 which accompanies this distribution. | ||
# | ||
# The Eclipse Public License is available at | ||
# http://www.eclipse.org/legal/epl-v10.html | ||
# | ||
# The Apache License v2.0 is available at | ||
# http://www.opensource.org/licenses/apache2.0.php | ||
# | ||
# Contributors: | ||
# Multiple authors (IBM Corp.) - initial implementation and documentation | ||
############################################################################### | ||
|
||
top_srcdir:=. | ||
include $(top_srcdir)/omrmakefiles/configure.mk | ||
|
||
### | ||
### Global targets | ||
### | ||
|
||
all: postbuild | ||
.DEFAULT: all | ||
clean: | ||
.PHONY: all clean | ||
|
||
help: | ||
@echo "help Display this help message." | ||
@echo "all Build OMR." | ||
@echo "clean Clean OMR build artifacts." | ||
@echo "test Run functional verification tests." | ||
.PHONY: help | ||
|
||
### | ||
### Tracegen | ||
### | ||
ifeq (yes,$(ENABLE_TRACEGEN)) | ||
define TRACEGEN_COMMAND | ||
cd $(exe_output_dir) && ./tracegen -treatWarningAsError -generatecfiles -threshold 1 -root $(top_srcdir) | ||
endef | ||
|
||
define TRACEMERGE_COMMAND | ||
cd $(exe_output_dir) && ./tracemerge -majorversion 5 -minorversion 1 -root $(top_srcdir) | ||
endef | ||
else | ||
define TRACEGEN_COMMAND | ||
@echo Skipping tracegen | ||
endef | ||
|
||
define TRACEMERGE_COMMAND | ||
@echo Skipping tracemerge | ||
endef | ||
endif | ||
|
||
|
||
# ASCII To EBCDIC Targets | ||
ifeq (zos,$(OMR_HOST_OS)) | ||
tool_targets += util/a2e | ||
endif | ||
|
||
tool_targets += tools/hookgen | ||
|
||
HOOK_DEFINITION_FILES := $(abspath ./gc/base/omrmmprivate.hdf ./gc/include/omrmm.hdf ./fvtest/algotest/hooksample.hdf) | ||
HOOK_DEFINITION_SENTINEL := $(patsubst %.hdf,%.sentinel, $(HOOK_DEFINITION_FILES)) | ||
define HOOKGEN_COMMAND | ||
cd $(exe_output_dir) && ./hookgen $< | ||
endef | ||
|
||
# Trace Build Tools | ||
ifeq (yes,$(ENABLE_TRACEGEN)) | ||
tool_targets += tools/tracegen | ||
main_targets += tools/tracemerge | ||
endif | ||
|
||
# FVTest Helper Libraries | ||
test_prereqs := third_party/pugixml-1.5 fvtest/util fvtest/omrGtestGlue | ||
test_targets += $(test_prereqs) | ||
|
||
# Utility Libraries | ||
main_targets += util/omrutil util/pool util/avl util/hashtable util/hookable | ||
test_targets += \ | ||
fvtest/algotest \ | ||
fvtest/utiltest | ||
|
||
# Thread Targets | ||
ifeq (1,$(OMR_THREAD)) | ||
main_targets += thread | ||
test_targets += fvtest/threadtest | ||
test_targets += fvtest/threadextendedtest | ||
endif | ||
|
||
# OMR GLue Target | ||
main_targets += omr_glue_static_lib | ||
|
||
# Garbage Collection Targets | ||
ifeq (1,$(OMR_GC)) | ||
main_targets += \ | ||
gc/base \ | ||
gc/base/standard \ | ||
gc/startup \ | ||
gc/stats \ | ||
gc/structs \ | ||
gc/verbose \ | ||
gc/verbose/handler_standard | ||
test_targets += fvtest/gctest | ||
test_targets += perftest/gctest | ||
endif | ||
|
||
# Omrsig Targets | ||
ifeq (1,$(OMR_OMRSIG)) | ||
main_targets += omrsigcompat | ||
test_targets += fvtest/sigtest | ||
endif | ||
|
||
# Portlibrary Targets | ||
ifeq (1,$(OMR_PORT)) | ||
main_targets += port | ||
test_targets += fvtest/porttest | ||
test_targets += fvtest/porttest/sltestlib | ||
ifeq (aix,$(OMR_HOST_OS)) | ||
test_targets += fvtest/porttest/aixbaddep | ||
endif | ||
endif | ||
|
||
# RAS Libraries | ||
main_targets += omrtrace | ||
|
||
# OMR Startup | ||
main_targets += omr omr/startup | ||
|
||
# RAS Tests | ||
test_targets += fvtest/rastest | ||
|
||
# OMR Example Targets | ||
ifeq (1,$(OMR_EXAMPLE)) | ||
test_targets += example | ||
endif | ||
|
||
# VM Tests | ||
test_targets += fvtest/vmtest | ||
|
||
DO_TEST_TARGET := yes | ||
# ENABLE_FVTEST_AGENT forces rastest to build, even if fvtests are disabled. | ||
ifeq (no,$(ENABLE_FVTEST)) | ||
DO_TEST_TARGET := no | ||
ifeq (yes,$(ENABLE_FVTEST_AGENT)) | ||
DO_TEST_TARGET := yes | ||
test_targets := $(test_prereqs) | ||
test_targets += fvtest/rastest fvtest/util | ||
endif | ||
endif | ||
|
||
### | ||
### Rules | ||
### | ||
|
||
# Remove duplicates | ||
main_targets := $(sort $(main_targets)) | ||
test_targets := $(sort $(test_targets)) | ||
|
||
targets := $(tool_targets) $(prebuild_targets) $(main_targets) omr_static_lib $(test_targets) | ||
targets_clean := $(addsuffix _clean,$(targets)) | ||
|
||
postbuild: tests | ||
$(TRACEMERGE_COMMAND) | ||
|
||
tests: staticlib | ||
|
||
ifeq (yes,$(DO_TEST_TARGET)) | ||
@$(MAKE) -f GNUmakefile $(test_targets) | ||
endif | ||
|
||
staticlib: mainbuild | ||
@$(MAKE) -f GNUmakefile omr_static_lib | ||
|
||
mainbuild: prebuild | ||
@$(MAKE) -f GNUmakefile $(main_targets) | ||
|
||
prebuild: tools | ||
@$(MAKE) -f GNUmakefile $(prebuild_targets) $(HOOK_DEFINITION_SENTINEL) | ||
$(TRACEGEN_COMMAND) | ||
|
||
tools: | ||
@$(MAKE) -f GNUmakefile $(tool_targets) | ||
|
||
.PHONY: tools prebuild mainbuild staticbuild tests postbuild | ||
|
||
### | ||
### Inter-target Dependencies | ||
### | ||
|
||
# These rules must be specified before $(targets):: | ||
|
||
# If a prereq directory is not also defined in $(targets), | ||
# then we won't execute 'make' in the prereq directory. | ||
|
||
ifeq (zos,$(OMR_HOST_OS)) | ||
tools/tracegen:: util/a2e | ||
tools/tracemerge:: util/a2e | ||
tools/hookgen:: util/a2e | ||
endif | ||
|
||
$(HOOK_DEFINITION_SENTINEL): $(exe_output_dir)/hookgen$(EXEEXT) | ||
%.sentinel: %.hdf | ||
$(HOOKGEN_COMMAND) | ||
touch $@ | ||
|
||
hook_definition_sentinel_clean: | ||
rm -f $(HOOK_DEFINITION_SENTINEL) | ||
|
||
omrsigcompat:: util/omrutil | ||
|
||
example:: $(test_prereqs) | ||
|
||
fvtest/algotest::$(test_prereqs) | ||
fvtest/gctest:: $(test_prereqs) | ||
fvtest/porttest:: $(test_prereqs) | ||
fvtest/rastest:: $(test_prereqs) | ||
fvtest/sigtest:: $(test_prereqs) | ||
fvtest/threadextendedtest:: $(test_prereqs) | ||
fvtest/threadtest:: $(test_prereqs) | ||
fvtest/utiltest:: $(test_prereqs) | ||
fvtest/vmtest:: $(test_prereqs) | ||
|
||
perftest/gctest:: $(test_prereqs) | ||
|
||
### | ||
### Targets | ||
### | ||
|
||
$(targets):: | ||
$(MAKE) -C $@ all | ||
.PHONY: $(targets) | ||
|
||
%: | ||
@echo Error, No rule to build target $@ | ||
@exit -1 | ||
|
||
clean: $(targets_clean) hook_definition_sentinel_clean | ||
$(targets_clean):: | ||
$(MAKE) -C $(patsubst %_clean,%,$@) clean | ||
.PHONY: $(targets_clean) | ||
|
||
test: | ||
ifeq (yes,$(ENABLE_FVTEST)) | ||
$(MAKE) -f fvtest/omrtest.mk test | ||
else | ||
@echo Functional verification tests are disabled. | ||
endif | ||
.PHONY: test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
(c) Copyright IBM Corp. 2016 | ||
|
||
This program and the accompanying materials are made available | ||
under the terms of the Eclipse Public License v1.0 and | ||
Apache License v2.0 which accompanies this distribution. | ||
|
||
The Eclipse Public License is available at | ||
http://www.eclipse.org/legal/epl-v10.html | ||
|
||
The Apache License v2.0 is available at | ||
http://www.opensource.org/licenses/apache2.0.php | ||
|
||
Contributors: | ||
Multiple authors (IBM Corp.) - initial implementation and documentation | ||
|
||
|
||
Building OMR | ||
============ | ||
The following packages are required to build OMR: | ||
|
||
- autoconf | ||
- curl | ||
- numa-dev (which provides numa.h) |
Oops, something went wrong.