Skip to content

[GEN][ZH] Implement file info generation for Generals executables #1291

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

xezon
Copy link

@xezon xezon commented Jul 15, 2025

This change implements file info generation for Generals executables.

Originally the EXE properties contained no information. The new information is set in CMake which then generates RC files for Windows executables. The generated information is not yet ideal, but a starting point for further tweaks.

Renamed targets "generalsv" to "GeneralsV" and "generalszh" to "GeneralsZH" on Windows.

VERSION_BUILDNUM is now set to 0 instead of 601.

image

@xezon xezon added this to the Code foundation build up milestone Jul 15, 2025
@xezon xezon requested a review from OmniBlade July 15, 2025 22:14
@xezon xezon added Minor Severity: Minor < Major < Critical < Blocker Gen Relates to Generals ZH Relates to Zero Hour labels Jul 15, 2025
Copy link

@OmniBlade OmniBlade left a comment

Choose a reason for hiding this comment

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

Quite a lot of duplication and only adds it to the main game binaries. I would suggest refactoring it into something that can generate a custom rc file per target that can then be linked. https://github.com/TheAssemblyArmada/Vanilla-Conquer/blob/vanilla/cmake/ProductVersion.cmake is an off the shelf cmake module someone wrote that I've tweaked a bit for Vanilla Conquer use which you could use or just take inspiration from?

@xezon
Copy link
Author

xezon commented Jul 16, 2025

Yes I planned to do a follow up change and move this to the resources target, so it can be reused in tools. Do you want it to be moved right away?

@OmniBlade
Copy link

Just makes sense to me to do it that way from the get go once you have it working? There is nothing technically wrong that I can see at a glance otherwise.

@fbraz3
Copy link

fbraz3 commented Jul 16, 2025

GenPatcher installs a GeneralsZH.exe file, I wondering it should be good to have a unique name.

@xezon
Copy link
Author

xezon commented Jul 16, 2025

To the game install directory?

@OmniBlade
Copy link

Just a thought, you could fill the copyright field with something like "Based on code released under the GPLv3" or just "GNU Public License Version 3" instead of leaving it blank?

@fbraz3
Copy link

fbraz3 commented Jul 16, 2025

To the game install directory?

Yeap. This is the reason I named the files GeneralsV.exe and generalsZHv.exe under my fork.

@fbraz3
Copy link

fbraz3 commented Jul 17, 2025

Just a thought, you could fill the copyright field with something like "Based on code released under the GPLv3" or just "GNU Public License Version 3" instead of leaving it blank?

+1 to this

@fbraz3
Copy link

fbraz3 commented Jul 17, 2025

What about to add this repo URL to File Descripton field?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Gen Relates to Generals Minor Severity: Minor < Major < Critical < Blocker ZH Relates to Zero Hour
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants