Skip to content
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

cmake: glob translation files #3124

Closed
wants to merge 1 commit into from

Conversation

milahu
Copy link

@milahu milahu commented Feb 17, 2023

allow to remove translations by

rm -rf src/translations/*

translation files should be single-sourced from https://github.com/rizinorg/cutter-translations

Your checklist for this pull request

Detailed description

Test plan (required)

Closing issues

Sorry, something went wrong.

allow to remove translations by

rm -rf src/translations/*
@XVilka
Copy link
Member

XVilka commented Feb 17, 2023

CMake Error: Attempt to add a custom rule to output "C:/projects/cutter/build/src/translations/cutter_pt.qm.rule" which already has a custom rule.

@milahu
Copy link
Author

milahu commented Feb 17, 2023

... because glob returns absolute paths

please try this on windows

# note: glob returns absolute paths
file(GLOB TS_FILES
    LIST_DIRECTORIES false
    CONFIGURE_DEPENDS
    "translations/*/cutter_*.ts"
)

message("debug: TS_FILES 1 = ${TS_FILES}")

# problems with fonts
list(FILTER TS_FILES EXCLUDE REGEX "translations/ko/cutter_ko.ts$")

# #2321 handling multiple versions of a language
list(FILTER TS_FILES EXCLUDE REGEX "translations/pt-BR/cutter_pt.ts$")

message("debug: TS_FILES 2 = ${TS_FILES}")

message(FATAL_ERROR "todo")

translations/pt-BR/cutter_pt.ts should not be in TS_FILES 2

@milahu milahu closed this Feb 17, 2023
@milahu
Copy link
Author

milahu commented Feb 17, 2023

oops

@milahu milahu reopened this Feb 17, 2023
@XVilka
Copy link
Member

XVilka commented Jun 26, 2023

@milahu please rebase.

@milahu
Copy link
Author

milahu commented Jun 26, 2023

abandoned

@milahu milahu closed this Jun 26, 2023
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.

None yet

2 participants