### Description
I want to debug `Kamailio` using `GDB` and compiled sources on `aarch64` architecture (`t4g` AWS instance).
But produces object files do not contain debug info.
Then executed
```
make -n
```
And found that no `-g` options used during compilation.
I have specified `CFLAGS` and `CPPFLAGS` but with wont help.
### Expected behavior
On all dist used `-g` compilation flag by default.
If I have specified `CFLAGS` and `CPPFLAGS` as environment variables, then these flags used by GCC during compilation.
#### Actual observed behavior
`-g` flag do not used by default on `aarch64` architecture.
`CFLAGS` and `CPPFLAGS` as environment variables do not used during compilation time.
### Additional info
as hotfix I have used this patch
```diff
diff --git a/src/Makefile.defs b/src/Makefile.defs
index 027c985798..c91c34a7bb 100644
--- a/src/Makefile.defs
+++ b/src/Makefile.defs
@@ -885,7 +885,7 @@ endif
ifeq ($(ARCH), aarch64)
use_fast_lock=yes
- C_DEFS+=-DNOSMP # memory barriers not implemented for arm
+ C_DEFS+= -g -DNOSMP # memory barriers not implemented for arm
endif
ifeq ($(ARCH), ppc)
```
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2789
#### Pre-Submission Checklist
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [x] Small bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
- [ ] PR should be backported to stable branches
- [ ] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
closes GH #2789
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2811
-- Commit Summary --
* core: enabled compilation with debug symbols by default
-- File Changes --
M src/Makefile.defs (66)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2811.patchhttps://github.com/kamailio/kamailio/pull/2811.diff
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/2811