Enable frame pointer in Ruby compile options
As seen in gitlab-com/gl-infra/production#939 (closed) and mentioned in http://www.brendangregg.com/perf.html:
Always compile with frame pointers. Omitting frame pointers is an evil compiler optimization that breaks debuggers, and sadly, is often the default. Without them, you may see incomplete stacks from perf_events.
This mimics what we did with gitlab-org/omnibus-gitlab!4030 (merged).
Build output shows:
CC = gcc
LD = ld
LDSHARED = gcc -shared
CFLAGS = -fno-omit-frame-pointer -O3 -ggdb3 -Wall -Wextra -Wdeprecated-declarations -Wduplicated-cond -Wimplicit-function-declaration -Wimplicit-int -Wmisleading-indentation -Wpointer-arith -Wwrite-strings -Wimplicit-fallthrough=0 -Wmissing-noreturn -Wno-cast-function-type -Wno-constant-logical-operand -Wno-long-long -Wno-missing-field-initializers -Wno-overlength-strings -Wno-packed-bitfield-compat -Wno-parentheses-equality -Wno-self-assign -Wno-tautological-compare -Wno-unused-parameter -Wno-unused-value -Wsuggest-attribute=format -Wsuggest-attribute=noreturn -Wunused-variable -std=gnu99 -fPIC
XCFLAGS = -D_FORTIFY_SOURCE=2 -fstack-protector-strong -fno-strict-overflow -fvisibility=hidden -fexcess-precision=standard -DRUBY_EXPORT -DCANONICALIZATION_FOR_MATHN -I. -I.ext/include/x86_64-linux -I./include -I. -I./enc/unicode/12.1.0
CPPFLAGS =
DLDFLAGS = -Wl,--compress-debug-sections=zlib -Wl,-soname,libruby.so.2.7 -fstack-protector-strong
SOLIBS = -lz -lpthread -lrt -lrt -ljemalloc -ldl -lcrypt -lm
LANG = C.UTF-8
LC_ALL =
LC_CTYPE =
MFLAGS = -j2 --jobserver-auth=4,5
Edited by Stan Hu