Skip to content

Commit

Permalink
Add ppc64 build option
Browse files Browse the repository at this point in the history
  • Loading branch information
Pavel-P committed Dec 16, 2019
1 parent 05f4598 commit ebd1dd7
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 1 deletion.
31 changes: 31 additions & 0 deletions BUILD.boost
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,15 @@ config_setting(
visibility = ["//visibility:public"],
)

config_setting(
name = "linux_ppc",
constraint_values = [
"@bazel_tools//platforms:linux",
"@bazel_tools//platforms:ppc",
],
visibility = ["//visibility:public"],
)

config_setting(
name = "linux_x86_64",
constraint_values = [
Expand Down Expand Up @@ -96,6 +105,11 @@ BOOST_CTX_ASM_SOURCES = select({
"libs/context/src/asm/make_arm_aapcs_elf_gas.S",
"libs/context/src/asm/ontop_arm_aapcs_elf_gas.S",
],
":linux_ppc": [
"libs/context/src/asm/jump_ppc64_sysv_elf_gas.S",
"libs/context/src/asm/make_ppc64_sysv_elf_gas.S",
"libs/context/src/asm/ontop_ppc64_sysv_elf_gas.S",
],
":linux_x86_64": [
"libs/context/src/asm/jump_x86_64_sysv_elf_gas.S",
"libs/context/src/asm/make_x86_64_sysv_elf_gas.S",
Expand Down Expand Up @@ -149,6 +163,10 @@ boost_library(
BOOST_FIBER_NUMA_SRCS = select({
":linux_arm": [
],
":linux_ppc": [
"libs/fiber/src/numa/linux/pin_thread.cpp",
"libs/fiber/src/numa/linux/topology.cpp",
], # MAYBE SHOULD BE BLANK
":linux_x86_64": [
"libs/fiber/src/numa/linux/pin_thread.cpp",
"libs/fiber/src/numa/linux/topology.cpp",
Expand Down Expand Up @@ -982,12 +1000,14 @@ boost_library(
name = "locale",
srcs = select({
":linux_arm": BOOST_LOCALE_POSIX_SOURCES,
":linux_ppc": BOOST_LOCALE_POSIX_SOURCES,
":linux_x86_64": BOOST_LOCALE_POSIX_SOURCES,
":osx_x86_64": BOOST_LOCALE_POSIX_SOURCES,
":windows_x86_64": BOOST_LOCALE_WIN32_SOURCES,
}),
copts = select({
":linux_arm": BOOST_LOCALE_POSIX_COPTS,
":linux_ppc": BOOST_LOCALE_POSIX_COPTS,
":linux_x86_64": BOOST_LOCALE_POSIX_COPTS,
":osx_x86_64": BOOST_LOCALE_POSIX_COPTS,
":windows_x86_64": BOOST_LOCALE_WIN32_COPTS,
Expand Down Expand Up @@ -1588,6 +1608,9 @@ BOOST_STACKTRACE_SOURCES = select({
"libs/stacktrace/src/basic.cpp",
"libs/stacktrace/src/noop.cpp",
],
":linux_ppc": [
"libs/stacktrace/src/backtrace.cpp",
],
":linux_x86_64": [
"libs/stacktrace/src/backtrace.cpp",
],
Expand All @@ -1611,6 +1634,9 @@ boost_library(
}),
exclude_src = ["libs/stacktrace/src/*.cpp"],
linkopts = select({
":linux_ppc": [
"-lbacktrace -ldl",
],
":linux_x86_64": [
"-lbacktrace -ldl",
],
Expand Down Expand Up @@ -1689,6 +1715,7 @@ boost_library(
}),
defines = select({
":linux_arm": [],
":linux_ppc": [],
":linux_x86_64": [],
":osx_x86_64": [],
":windows_x86_64": [
Expand Down Expand Up @@ -2017,6 +2044,8 @@ boost_library(
BOOST_LOG_CFLAGS = select({
":linux_arm": [
],
":linux_ppc": [
],
":x86_64": [
"-msse4.2",
],
Expand Down Expand Up @@ -2049,6 +2078,8 @@ BOOST_LOG_DEPS = [
BOOST_LOG_SSSE3_DEP = select({
":linux_arm": [
],
":linux_ppc": [
],
":x86_64": [
":log_dump_ssse3",
],
Expand Down
2 changes: 1 addition & 1 deletion config.lzma-linux.h
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@
/* #undef HAVE_ICONV */

/* Define to 1 if you have the <immintrin.h> header file. */
#define HAVE_IMMINTRIN_H 1
#undef HAVE_IMMINTRIN_H

/* Define to 1 if you have the <inttypes.h> header file. */
#define HAVE_INTTYPES_H 1
Expand Down

0 comments on commit ebd1dd7

Please sign in to comment.