Skip to content

Conversation

@chipbarnaby
Copy link
Contributor

@chipbarnaby chipbarnaby commented Aug 4, 2023

Description

Rework build scheme so rcdef does not use dtypes.h, eliminating circular dependency. This allows straightforward switch between 32 and 64 bit builds.

Files included in the rcdef build have been modified to compile using only a small subset of dtypes.h definitions. Those are provided in cnglob.h when NODTYPES is #defined. Some dtypes.h typedef types have been coded out in non-cnrecs.def usage (notably BOO (= short integer) has been replaced by bool).

Also combined build and test jobs in the CI workflow. This allows unit tests to use the current dtypes.h.

@@ -1,7 +1,9 @@
cmake_minimum_required(VERSION 3.15.0)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this a necessary update?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CMake stuff I've read recommends putting cmake-minimum_required as the first thing in the file, so I moved it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But no particular reason to upgrade to 3.15 from 3.10?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually the change was inadvertent. I have done some reading in Professional CMake and noted many features added in 3.15 related to debugging, clang-on-Windows-support, and other things. Given that 3.15 is now 4 years old, it is not unreasonable to require it. In fact, I would advocate going much newer and learning how to exploit current features. We're a small group, it would not be a major inconvenience to move to a newer version.

src/libstubs.cpp Outdated
Comment on lines 8 to 14
#if 0
#include "cnglob.h"
#include "vrpak.h"

VROUTINFO5 PriRep = { { 0 } };
const char* InputFilePathNoExt = NULL;
#endif
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need this or not? If it is sticking around, should have some comments about why.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree it should be deleted, will do that.

xiopak.unit.cpp
cvpak.unit.cpp
$<TARGET_OBJECTS:cse_libstubs>
../../src/libstubs.cpp
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use ${CSE_SOURCE_DIR} instead of ../../src.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK

@nealkruis nealkruis changed the title Rcdef untangle Eliminate circular DTYPES dependency in RCDEF Aug 7, 2023
@nealkruis nealkruis self-requested a review August 9, 2023 16:36
@nealkruis nealkruis merged commit fe76776 into main Aug 9, 2023
@nealkruis nealkruis deleted the rcdef-untangle branch August 9, 2023 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants