]> Kevux Git Server - fll/commitdiff
Update: Provide the program name in the main library of status_code.
authorKevin Day <thekevinday@gmail.com>
Wed, 9 Nov 2022 00:06:22 +0000 (18:06 -0600)
committerKevin Day <thekevinday@gmail.com>
Wed, 9 Nov 2022 00:06:22 +0000 (18:06 -0600)
Looks like I can still include the standard program name in common.c without causing any problems by having an override in main-status_code.c.

level_3/status_code/c/common.c
level_3/status_code/c/main-status_code.c

index 8a6601c2323c948a4eefd45b90085e368e61f036..b21cf92c26efb03727191f5b4fb1b41c504d5df2 100644 (file)
@@ -8,6 +8,11 @@ extern "C" {
   const f_string_static_t status_code_program_version_s = macro_f_string_static_t_initialize(STATUS_CODE_program_version_s, 0, STATUS_CODE_program_version_s_length);
 #endif // _di_status_code_program_version_
 
+#ifndef _di_status_code_program_name_
+  const f_string_static_t status_code_program_name_s = macro_f_string_static_t_initialize(STATUS_CODE_program_name_s, 0, STATUS_CODE_program_name_s_length);
+  const f_string_static_t status_code_program_name_long_s = macro_f_string_static_t_initialize(STATUS_CODE_program_name_long_s, 0, STATUS_CODE_program_name_long_s_length);
+#endif // _di_status_code_program_name_
+
 #ifndef _di_status_code_program_help_parameters_
   const f_string_static_t status_code_program_help_parameters_s = macro_f_string_static_t_initialize(STATUS_CODE_program_help_parameters_s, 0, STATUS_CODE_program_help_parameters_s_length);
 #endif // _di_status_code_program_help_parameters_
index e5dde749148041e87e7d502be1c2bb31125e8625..5c7ac19ffd0fbecf756e5625b3274b39cbe06a5e 100644 (file)
@@ -1,10 +1,5 @@
 #include "status_code.h"
 
-#ifndef _di_status_code_program_name_
-  const f_string_static_t status_code_program_name_s = macro_f_string_static_t_initialize(STATUS_CODE_program_name_s, 0, STATUS_CODE_program_name_s_length);
-  const f_string_static_t status_code_program_name_long_s = macro_f_string_static_t_initialize(STATUS_CODE_program_name_long_s, 0, STATUS_CODE_program_name_long_s_length);
-#endif // _di_status_code_program_name_
-
 int main(const int argc, const f_string_t *argv, const f_string_t *envp) {
 
   fll_program_data_t data = fll_program_data_t_initialize;