AmigaPorts / AmigaPorts/ACE

static builds of ACE ignore its build flags

未關閉
#225 1 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視
bug help wanted
主要語言
C
星號
223
分支
38
平均合併
1 天 5 小時
30 天內合併 PR
6

描述

Steps to reproduce:

- build libace.a with `ACE_DEBUG` cmake switch set to `ON` - this will set the define with same name
- `make install` the ACE library
- use `find_library()` to include libace in your project

Expected behavior:

- `ACE_DEBUG` define persists and is used in ACE headers

Actual behavior:

- `ACE_DEBUG` is not set when building user's project, because it's only set when calling the ACE's CMakeLists.txt

Possible solution variant 1:

When installing the library, create the cmake script which will be called upon finding the ACE library, which will set same defines as its build phase.
That could be done with generating custom FindACE.cmake and installing it along with the library.
This should work, but my gut tells me it's not the way to go.

Possible solution variant 2:

When building the library, `ace_config.h` could be created, which would store all the required ACE defines. this would also clear up the compile commands a bit, making it a bit lighter on parameter-specified defines. This works similarly to libjpeg and other "big" and "serious" libraries, so I think it's a good pattern to pursue.

貢獻指南

這個儲存庫沒有索引到貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。