Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Placeholder for RHEL9 workaround #132

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions bin/getgcc
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ class SystemSetup(paella.Setup):
# self.run("apt-get install -y -t testing build-essential", sudo=True)
# self.run("update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-10 10", sudo=True)
# self.run("update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-10 10", sudo=True)
#

def redhat_compat(self):
self.group_install("'Development Tools'")
Expand All @@ -61,6 +62,8 @@ class SystemSetup(paella.Setup):
self.install("gcc-toolset-11-libatomic-devel")
self.run("rm -f {}/gcc-toolset-*.sh".format(self.profile_d), sudo=True)
self.cp_to_profile_d("/opt/rh/gcc-toolset-11/enable", "gcc-toolset-11.sh")
elif self.osnick == 'centos9':
self.install("gcc-toolset-12-gcc gcc-toolset-12-gcc-c++ gcc-toolset-12-libatomic-devel autoconf automake libtool")
elif self.dist == 'amzn' and self.os_version[0] == 2:
self.install("devtoolset-11-gcc devtoolset-11-gcc-c++ devtoolset-11-make")
# self.install("devtoolset-11-libatomic-devel")
Expand Down
30 changes: 16 additions & 14 deletions bin/getredis
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class RedisSourceSetup(paella.Setup):
raise RuntimeError('conflicting arguments: version, branch')
self.version = args.version
self.branch = args.branch

self.valgrind = args.valgrind
self.libc_malloc = args.libc_malloc
self.clang_asan = args.clang_asan
Expand Down Expand Up @@ -181,7 +181,7 @@ class RedisSourceSetup(paella.Setup):
self.run('tar -C {DIR} -xzf {FILE}'.format(DIR=self.base_dir, FILE=file))
paella.mkdir_p(ssl_dir)
prefix_dir = '{DIR}/{PREFIX}'.format(DIR=self.base_dir, PREFIX=prefix)

platform = paella.Platform()
arch = ''
if platform.os == 'linux':
Expand Down Expand Up @@ -286,7 +286,7 @@ class RedisSourceSetup(paella.Setup):
if self.cc == "gcc":
build_args += ['LDFLAGS="-static-libgcc"']
openssl_build_args = []

if args.clang_san_blacklist is not None:
blacklist_arg = '-fsanitize-blacklist=%s' % args.clang_san_blacklist
else:
Expand All @@ -299,7 +299,7 @@ class RedisSourceSetup(paella.Setup):
'MALLOC="libc"',
'CFLAGS="-fsanitize=address ' +
'-fno-omit-frame-pointer -fno-optimize-sibling-calls -fsanitize-address-use-after-scope ' +
blacklist_arg + ' ' +
blacklist_arg + ' ' +
'"',
'LDFLAGS="-fsanitize=address"',
]
Expand All @@ -308,7 +308,7 @@ class RedisSourceSetup(paella.Setup):
'LD=clang',
'CFLAGS="-O1 -fsanitize=address ' +
'-fno-omit-frame-pointer -fno-optimize-sibling-calls -fsanitize-address-use-after-scope ' +
blacklist_arg + ' ' +
blacklist_arg + ' ' +
'"',
'LDFLAGS="-fsanitize=address"',
]
Expand All @@ -324,8 +324,8 @@ class RedisSourceSetup(paella.Setup):
'OPTIMIZATION="-O2"',
'MALLOC=libc',
'CFLAGS="-fsanitize=memory ' +
'-fno-omit-frame-pointer -fPIC -fsanitize-memory-track-origins ' +
blacklist_arg + ' ' +
'-fno-omit-frame-pointer -fPIC -fsanitize-memory-track-origins ' +
blacklist_arg + ' ' +
# '-stdlib=libc++ ' +
# ('-Wl,-rpath=%s/lib ' % llvm_dir) +
# ('-L%s/lib ' % llvm_dir) +
Expand All @@ -338,8 +338,8 @@ class RedisSourceSetup(paella.Setup):
'CC=clang',
'LD=clang',
'CFLAGS="-O2 -fsanitize=memory ' +
'-fno-omit-frame-pointer -fPIC -fsanitize-memory-track-origins ' +
blacklist_arg + ' ' +
'-fno-omit-frame-pointer -fPIC -fsanitize-memory-track-origins ' +
blacklist_arg + ' ' +
'"',
'LDFLAGS="-fsanitize=memory"']

Expand Down Expand Up @@ -378,7 +378,7 @@ class RedisSourceSetup(paella.Setup):
self.redis_server = os.path.join(into_bindir, 'redis-server-' + self.suffix)
else:
self.redis_server = os.path.join(into_bindir, 'redis-server')

if not self.keep:
paella.rm_rf(self.base_dir)
if self.info_file is not None:
Expand All @@ -388,12 +388,14 @@ class RedisSourceSetup(paella.Setup):
""".format(base_dir=os.path.abspath(self.base_dir), build_dir=os.path.abspath(self.build_dir))
info = textwrap.dedent(info).split("\n", 1)[1]
paella.fwrite(self.info_file, info)

#------------------------------------------------------------------------------------------

def common_first(self):
if self.no_prepare:
return
if self.osnick == 'centos9':
return
self.install_downloaders()
self.install("git")

Expand Down Expand Up @@ -435,7 +437,7 @@ class RedisSourceSetup(paella.Setup):
self.build_redis()
if not self.no_run:
self.run("%s --version" % self.redis_server)


#----------------------------------------------------------------------------------------------

Expand All @@ -460,7 +462,7 @@ class RedisRepoSetup(paella.Setup):

def fedora(self):
self.install("dnf-plugins-core")

self.install("--allowerasing https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm")
self.install("http://rpms.remirepo.net/enterprise/remi-release-7.rpm")
self.run("dnf config-manager -y --set-enabled remi", sudo=True)
Expand Down
2 changes: 1 addition & 1 deletion bin/getrmpytools
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ class RMPyToolsSetup(paella.Setup):
self.install("git")
if self.reinstall:
self.pip_uninstall("redis redis-py-cluster ramp-packer RLTest")

if self.master:
self.redispy_org = 'redis'
self.redispy_version = 'master'
Expand Down
2 changes: 2 additions & 0 deletions mk/osnick.defs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ ifeq ($(OS.custom),)
OS.centos7=centos:7
OS.centos7.8=centos:7.8.2003
OS.centos8=centos:8
OS.centos9=rockylinux:9
OS.centos8.3=centos:8.2011
OS.fedora=fedora:latest
OS.fedora37=fedora:37
Expand All @@ -28,6 +29,7 @@ OS.alpine3=alpine:latest
OS.ol8=oraclelinux:8
OS.alma8=almalinux:8
OS.rocky8=rockylinux:8
OS.rocky9=rockylinux:9
OS.jammy=ubuntu:jammy
OS.amzn2=amazonlinux:2
OS.amzn2022=amazonlinux:2022
Expand Down