gwenhywfar  5.10.1
project.c
Go to the documentation of this file.
1 /***************************************************************************
2  begin : Mon Feb 08 2021
3  copyright : (C) 2021 by Martin Preuss
4  email : martin@libchipcard.de
5 
6  ***************************************************************************
7  * Please see toplevel file COPYING for license details *
8  ***************************************************************************/
9 
10 #ifdef HAVE_CONFIG_H
11 # include <config.h>
12 #endif
13 
14 
15 #include "gwenbuild/types/project_p.h"
16 
17 #include <gwenhywfar/memory.h>
18 #include <gwenhywfar/debug.h>
19 
20 
21 
22 
23 static void _writeFileFlagsToXml(uint32_t flags, GWEN_XMLNODE *xmlNode, const char *varName);
24 /* static uint32_t _readFlagsFromChar(const char *flagsAsText); */
25 
26 
27 
28 
29 
31 {
32  GWB_PROJECT *project;
33 
34  GWEN_NEW_OBJECT(GWB_PROJECT, project);
35 
36  project->gwbuild=gwbuild;
37  project->contextTree=ctx;
38 
39  project->fileList=GWB_File_List2_new();
40  project->targetList=GWB_Target_List2_new();
41  project->builderList=GWB_Builder_List2_new();
42  project->optionList=GWB_Option_List_new();
43  project->givenOptionList=GWB_KeyValuePair_List_new();
44  project->explicitBuildList=GWB_BuildCmd_List_new();
45 
46  return project;
47 }
48 
49 
50 
52 {
53  if (project) {
54  GWB_KeyValuePair_List_free(project->givenOptionList);
55  GWB_Option_List_free(project->optionList);
56  GWB_File_List2_free(project->fileList);
57  GWB_Context_free(project->contextTree);
58  GWB_Target_List2_free(project->targetList);
59  GWB_Builder_List2_free(project->builderList);
60  GWB_KeyValuePair_List_free(project->defineList);
61  free(project->versionTag);
62  GWB_BuildCmd_List_free(project->explicitBuildList);
63 
64  GWEN_FREE_OBJECT(project);
65  }
66 }
67 
68 
69 
71 {
72  return project->gwbuild;
73 }
74 
75 
76 
77 const char *GWB_Project_GetProjectName(const GWB_PROJECT *project)
78 {
79  return project->projectName;
80 }
81 
82 
83 
84 void GWB_Project_SetProjectName(GWB_PROJECT *project, const char *s)
85 {
86  if (project->projectName)
87  free(project->projectName);
88  if (s)
89  project->projectName=strdup(s);
90  else
91  project->projectName=NULL;
92 }
93 
94 
95 
96 void GWB_Project_SetVersion(GWB_PROJECT *project, int vMajor, int vMinor, int vPatchlevel, int vBuild, const char *vTag)
97 {
98  project->versionMajor=vMajor;
99  project->versionMinor=vMinor;
100  project->versionPatchlevel=vPatchlevel;
101  project->versionBuild=vBuild;
102  free(project->versionTag);
103  project->versionTag=vTag?strdup(vTag):NULL;
104 }
105 
106 
107 
109 {
110  return project->versionMajor;
111 }
112 
113 
114 
116 {
117  return project->versionMinor;
118 }
119 
120 
121 
123 {
124  return project->versionPatchlevel;
125 }
126 
127 
128 
130 {
131  return project->versionBuild;
132 }
133 
134 
135 
136 const char *GWB_Project_GetVersionTag(const GWB_PROJECT *project)
137 {
138  return project->versionTag;
139 }
140 
141 
142 
143 void GWB_Project_SetSoVersion(GWB_PROJECT *project, int vCurrent, int vAge, int vRevision)
144 {
145  project->soVersionCurrent=vCurrent;
146  project->soVersionAge=vAge;
147  project->soVersionRevision=vRevision;
148 }
149 
150 
151 
153 {
154  return project->soVersionCurrent;
155 }
156 
157 
158 
160 {
161  return project->soVersionAge;
162 }
163 
164 
165 
167 {
168  return project->soVersionRevision;
169 }
170 
171 
172 
173 uint32_t GWB_Project_GetFlags(const GWB_PROJECT *project)
174 {
175  return project->flags;
176 }
177 
178 
179 
180 void GWB_Project_SetFlags(GWB_PROJECT *project, uint32_t fl)
181 {
182  project->flags=fl;
183 }
184 
185 
186 
187 void GWB_Project_AddFlags(GWB_PROJECT *project, uint32_t fl)
188 {
189  project->flags|=fl;
190 }
191 
192 
193 
194 void GWB_Project_DelFlags(GWB_PROJECT *project, uint32_t fl)
195 {
196  project->flags&=~fl;
197 }
198 
199 
200 
201 
202 
203 
204 
205 GWB_FILE_LIST2 *GWB_Project_GetFileList(const GWB_PROJECT *project)
206 {
207  return project->fileList;
208 }
209 
210 
211 
212 GWB_FILE *GWB_Project_GetFileByPathAndName(const GWB_PROJECT *project, const char *folder, const char *fname)
213 {
214  return GWB_File_List2_GetFileByPathAndName(project->fileList, folder, fname);
215 }
216 
217 
218 
220 {
221  GWB_File_List2_PushBack(project->fileList, file);
222 }
223 
224 
225 
227 {
228  return project->contextTree;
229 }
230 
231 
232 
233 
234 GWB_TARGET_LIST2 *GWB_Project_GetTargetList(const GWB_PROJECT *project)
235 {
236  return project->targetList;
237 }
238 
239 
240 
242 {
243  GWB_Target_List2_PushBack(project->targetList, target);
244 }
245 
246 
247 
248 GWB_TARGET *GWB_Project_GetTargetById(const GWB_PROJECT *project, const char *id)
249 {
250  if (project->targetList) {
251  GWB_TARGET_LIST2_ITERATOR *it;
252 
253  it=GWB_Target_List2_First(project->targetList);
254  if (it) {
255  GWB_TARGET *target;
256 
257  target=GWB_Target_List2Iterator_Data(it);
258  while(target) {
259  const char *s;
260 
261  s=GWB_Target_GetId(target);
262  if (s && strcasecmp(s, id)==0)
263  break;
264  target=GWB_Target_List2Iterator_Next(it);
265  }
266  GWB_Target_List2Iterator_free(it);
267  if (target)
268  return target;
269  }
270  }
271 
272  return NULL;
273 }
274 
275 
276 
277 GWB_BUILDER_LIST2 *GWB_Project_GetBuilderList(const GWB_PROJECT *project)
278 {
279  return project->builderList;
280 }
281 
282 
283 
285 {
286  GWB_Builder_List2_PushBack(project->builderList, builder);
287 }
288 
289 
290 
291 GWB_KEYVALUEPAIR_LIST *GWB_Project_GetDefineList(const GWB_PROJECT *project)
292 {
293  return project->defineList;
294 }
295 
296 
297 
298 void GWB_Project_SetDefine(GWB_PROJECT *project, const char *name, const char *value)
299 {
300  if (name && *name) {
301  GWB_KEYVALUEPAIR *kvp;
302 
303  if (project->defineList==NULL)
304  project->defineList=GWB_KeyValuePair_List_new();
305 
306  kvp=GWB_KeyValuePair_List_GetFirstByKey(project->defineList, name);
307  if (kvp)
308  GWB_KeyValuePair_SetValue(kvp, value);
309  else
310  GWB_KeyValuePair_List_Add(GWB_KeyValuePair_new(name, value), project->defineList);
311  }
312 }
313 
314 
315 
316 void GWB_Project_SetDefineQuoted(GWB_PROJECT *project, const char *name, const char *value)
317 {
318  GWEN_BUFFER *dbuf;
319 
320  dbuf=GWEN_Buffer_new(0, 256, 0, 1);
321  GWEN_Buffer_AppendString(dbuf, "\"");
322  if (value && *value)
323  GWEN_Buffer_AppendString(dbuf, value);
324  GWEN_Buffer_AppendString(dbuf, "\"");
325  GWB_Project_SetDefine(project, name, GWEN_Buffer_GetStart(dbuf));
326  GWEN_Buffer_free(dbuf);
327 }
328 
329 
330 
332 {
333 if (project->defineList==NULL)
334  project->defineList=GWB_KeyValuePair_List_new();
335  else
336  GWB_KeyValuePair_List_Clear(project->defineList);
337 }
338 
339 
340 
341 GWB_OPTION_LIST *GWB_Project_GetOptionList(const GWB_PROJECT *project)
342 {
343  return project->optionList;
344 }
345 
346 
347 
349 {
350  GWB_Option_List_Add(option, project->optionList);
351 }
352 
353 
354 
355 GWB_OPTION *GWB_Project_GetOptionById(const GWB_PROJECT *project, const char *optionId)
356 {
357  GWB_OPTION *option;
358 
359  option=GWB_Option_List_First(project->optionList);
360  while(option) {
361  const char *sName;
362 
363  sName=GWB_Option_GetId(option);
364  if (sName && strcasecmp(sName, optionId)==0)
365  return option;
366  option=GWB_Option_List_Next(option);
367  }
368 
369  return NULL;
370 }
371 
372 
373 
374 GWB_KEYVALUEPAIR_LIST *GWB_Project_GetGivenOptionList(const GWB_PROJECT *project)
375 {
376  return project->givenOptionList;
377 }
378 
379 
380 
381 void GWB_Project_SetGivenOptionList(GWB_PROJECT *project, GWB_KEYVALUEPAIR_LIST *kvpList)
382 {
383  GWB_KeyValuePair_List_free(project->givenOptionList);
384  project->givenOptionList=kvpList;
385 }
386 
387 
388 
389 void GWB_Project_SetGivenOption(GWB_PROJECT *project, const char *name, const char *value)
390 {
391  GWB_KEYVALUEPAIR *kvp;
392 
393  kvp=GWB_KeyValuePair_new(name, value);
394  GWB_KeyValuePair_List_Add(kvp, project->givenOptionList);
395 }
396 
397 
398 
399 const char *GWB_Project_GetGivenOption(const GWB_PROJECT *project, const char *name)
400 {
401  return GWB_KeyValuePair_List_GetValue(project->givenOptionList, name);
402 }
403 
404 
405 
406 GWB_BUILD_CMD_LIST *GWB_Project_GetExplicitBuildList(const GWB_PROJECT *project)
407 {
408  return project->explicitBuildList;
409 }
410 
411 
412 
414 {
415  GWB_BuildCmd_List_Add(bcmd, project->explicitBuildList);
416 }
417 
418 
419 
420 void GWB_Project_toXml(const GWB_PROJECT *project, GWEN_XMLNODE *xmlNode)
421 {
422  if (project->projectName)
423  GWEN_XMLNode_SetCharValue(xmlNode, "projectName", project->projectName);
424  GWEN_XMLNode_SetIntValue(xmlNode, "versionMajor", project->versionMajor);
425  GWEN_XMLNode_SetIntValue(xmlNode, "versionMinor", project->versionMinor);
426  GWEN_XMLNode_SetIntValue(xmlNode, "versionPatchlevel", project->versionPatchlevel);
427  GWEN_XMLNode_SetIntValue(xmlNode, "versionBuild", project->versionBuild);
428  if (project->versionTag)
429  GWEN_XMLNode_SetCharValue(xmlNode, "versionTag", project->versionTag);
430 
431  GWEN_XMLNode_SetIntValue(xmlNode, "soVersionCurrent", project->soVersionCurrent);
432  GWEN_XMLNode_SetIntValue(xmlNode, "soVersionAge", project->soVersionAge);
433  GWEN_XMLNode_SetIntValue(xmlNode, "soVersionRevision", project->soVersionRevision);
434 
435  _writeFileFlagsToXml(GWB_Project_GetFlags(project), xmlNode, "flags");
436 
437  if (project->defineList) {
438  GWEN_XMLNODE *n;
439 
440  n=GWEN_XMLNode_new(GWEN_XMLNodeTypeTag, "DefineList");
441  GWB_KeyValuePair_List_WriteXml(project->defineList, n, "Define");
442  GWEN_XMLNode_AddChild(xmlNode, n);
443  }
444 
445  if (project->givenOptionList) {
446  GWEN_XMLNODE *n;
447 
448  n=GWEN_XMLNode_new(GWEN_XMLNodeTypeTag, "GivenOptionList");
449  GWB_KeyValuePair_List_WriteXml(project->givenOptionList, n, "GivenOption");
450  GWEN_XMLNode_AddChild(xmlNode, n);
451  }
452 
453  if (project->explicitBuildList) {
454  GWEN_XMLNODE *n;
455 
456  n=GWEN_XMLNode_new(GWEN_XMLNodeTypeTag, "ExplicitBuildCmdList");
457  GWB_BuildCmd_List_WriteXml(project->explicitBuildList, n, "BuildCmd");
458  GWEN_XMLNode_AddChild(xmlNode, n);
459  }
460 
461  if (project->fileList) {
462  GWEN_XMLNODE *n;
463 
464  n=GWEN_XMLNode_new(GWEN_XMLNodeTypeTag, "FileList");
465  GWB_File_List2_WriteXml(project->fileList, n, "File");
466  GWEN_XMLNode_AddChild(xmlNode, n);
467  }
468 
469 }
470 
471 
472 
473 void _writeFileFlagsToXml(uint32_t flags, GWEN_XMLNODE *xmlNode, const char *varName)
474 {
475  if (flags) {
476  GWEN_BUFFER *dbuf;
477 
478  dbuf=GWEN_Buffer_new(0, 256, 0, 1);
479 
480  if (flags & GWB_PROJECT_FLAGS_SHARED) {
481  if (GWEN_Buffer_GetUsedBytes(dbuf))
482  GWEN_Buffer_AppendString(dbuf, " ");
483  GWEN_Buffer_AppendString(dbuf, "SHARED");
484  }
485 
486  if (flags & GWB_PROJECT_FLAGS_CONFIG_H) {
487  if (GWEN_Buffer_GetUsedBytes(dbuf))
488  GWEN_Buffer_AppendString(dbuf, " ");
489  GWEN_Buffer_AppendString(dbuf, "CONFIG_H");
490  }
491 
492  if (GWEN_Buffer_GetUsedBytes(dbuf))
493  GWEN_XMLNode_SetCharValue(xmlNode, varName, GWEN_Buffer_GetStart(dbuf));
494  GWEN_Buffer_free(dbuf);
495  }
496 }
497 
498 
499 #if 0
500 uint32_t _readFlagsFromChar(const char *flagsAsText)
501 {
502  GWEN_STRINGLIST *sl;
503  uint32_t flags=0;
504 
505  sl=GWEN_StringList_fromString(flagsAsText, " ", 1);
506  if (sl) {
508 
510  while(se) {
511  const char *s;
512 
514  if (s && *s) {
515  if (strcasecmp(s, "SHARED")==0)
517  else if (strcasecmp(s, "CONFIG_H")==0)
519  else {
520  DBG_ERROR(NULL, "Unexpected PROJECT flag \"%s\"", s);
521  }
522  }
524  }
526  }
527 
528  return flags;
529 }
530 #endif
531 
532 
533 
534 
535 
536 
537 
538 void GWB_Project_Dump(const GWB_PROJECT *project, int indent, int fullDump)
539 {
540  int i;
541 
542  for(i=0; i<indent; i++)
543  fprintf(stderr, " ");
544  fprintf(stderr, "Project:\n");
545 
546  GWBUILD_Debug_PrintValue( "projectName......", project->projectName, indent+2);
547  GWBUILD_Debug_PrintIntValue("versionMajor.....", project->versionMajor, indent+2);
548  GWBUILD_Debug_PrintIntValue("versionMinor.....", project->versionMinor, indent+2);
549  GWBUILD_Debug_PrintIntValue("versionPatchlevel", project->versionPatchlevel, indent+2);
550  GWBUILD_Debug_PrintIntValue("versionBuild.....", project->versionBuild, indent+2);
551  GWBUILD_Debug_PrintValue( "versionTag.......", project->versionTag, indent+2);
552  GWBUILD_Debug_PrintIntValue("soVersionCurrent.", project->soVersionCurrent, indent+2);
553  GWBUILD_Debug_PrintIntValue("soVersionAge.....", project->soVersionAge, indent+2);
554  GWBUILD_Debug_PrintIntValue("soVersionRevision", project->soVersionRevision, indent+2);
555 
556  for(i=0; i<indent; i++)
557  fprintf(stderr, " ");
558  fprintf(stderr, "flags...........:");
559  if (project->flags & GWB_PROJECT_FLAGS_SHARED)
560  fprintf(stderr, " SHARED");
561  fprintf(stderr, "\n");
562 
563  GWB_Context_Tree2_Dump(project->contextTree, indent+2);
564 
565  GWBUILD_Debug_PrintFileList2("fileList", project->fileList, indent+2);
566  GWBUILD_Debug_PrintTargetList2("targetList", project->targetList, indent+2, fullDump);
567  GWBUILD_Debug_PrintKvpList("defineList", project->defineList, indent+2);
568  GWBUILD_Debug_PrintKvpList("givenOptionList", project->givenOptionList, indent+2);
569  GWBUILD_Debug_PrintBuilderList2("builderList", project->builderList, indent+2, fullDump);
570  GWBUILD_Debug_PrintOptionList("optionList", project->optionList, indent+2);
571 }
572 
573 
574 
575 
GWB_BUILDER_LIST2 * GWB_Project_GetBuilderList(const GWB_PROJECT *project)
Definition: project.c:277
void GWBUILD_Debug_PrintIntValue(const char *sName, int value, int indent)
Definition: gwenbuild.c:236
char * GWEN_Buffer_GetStart(const GWEN_BUFFER *bf)
Definition: buffer.c:235
struct GWEN_STRINGLISTENTRYSTRUCT GWEN_STRINGLISTENTRY
Definition: stringlist.h:53
void GWB_Project_DelFlags(GWB_PROJECT *project, uint32_t fl)
Definition: project.c:194
struct GWB_CONTEXT GWB_CONTEXT
Definition: context.h:17
void GWB_Project_free(GWB_PROJECT *project)
Definition: project.c:51
uint32_t GWEN_Buffer_GetUsedBytes(const GWEN_BUFFER *bf)
Definition: buffer.c:277
const char * GWB_Project_GetVersionTag(const GWB_PROJECT *project)
Definition: project.c:136
#define GWB_PROJECT_FLAGS_SHARED
Definition: project.h:26
GWENBUILD * GWB_Project_GetGwbuild(const GWB_PROJECT *project)
Definition: project.c:70
struct GWB_OPTION GWB_OPTION
Definition: option.h:17
void GWB_KeyValuePair_List_WriteXml(const GWB_KEYVALUEPAIR_LIST *kvpList, GWEN_XMLNODE *xmlNode, const char *groupName)
Definition: keyvaluepair.c:240
struct GWB_FILE GWB_FILE
Definition: file.h:18
void GWB_Project_AddExplicitBuild(GWB_PROJECT *project, GWB_BUILD_CMD *bcmd)
Definition: project.c:413
GWB_KEYVALUEPAIR_LIST * GWB_Project_GetDefineList(const GWB_PROJECT *project)
Definition: project.c:291
#define GWEN_FREE_OBJECT(varname)
Definition: memory.h:61
void GWB_Project_Dump(const GWB_PROJECT *project, int indent, int fullDump)
Definition: project.c:538
#define NULL
Definition: binreloc.c:300
GWB_PROJECT * GWB_Project_new(GWENBUILD *gwbuild, GWB_CONTEXT *ctx)
Definition: project.c:30
void GWBUILD_Debug_PrintTargetList2(const char *sName, const GWB_TARGET_LIST2 *targetList2, int indent, int fullDump)
Definition: gwenbuild.c:361
void GWB_Project_AddFlags(GWB_PROJECT *project, uint32_t fl)
Definition: project.c:187
void GWB_Project_SetFlags(GWB_PROJECT *project, uint32_t fl)
Definition: project.c:180
GWB_TARGET_LIST2 * GWB_Project_GetTargetList(const GWB_PROJECT *project)
Definition: project.c:234
void GWB_Project_SetDefine(GWB_PROJECT *project, const char *name, const char *value)
Definition: project.c:298
struct GWB_PROJECT GWB_PROJECT
Definition: project.h:14
GWB_OPTION_LIST * GWB_Project_GetOptionList(const GWB_PROJECT *project)
Definition: project.c:341
void GWB_KeyValuePair_SetValue(GWB_KEYVALUEPAIR *kvp, const char *s)
Definition: keyvaluepair.c:104
void GWEN_XMLNode_SetCharValue(GWEN_XMLNODE *n, const char *name, const char *value)
Definition: xml.c:897
int GWB_Project_GetVersionBuild(const GWB_PROJECT *project)
Definition: project.c:129
GWEN_XMLNODE * GWEN_XMLNode_new(GWEN_XMLNODE_TYPE t, const char *data)
Definition: xml.c:144
GWEN_BUFFER * GWEN_Buffer_new(char *buffer, uint32_t size, uint32_t used, int take)
Definition: buffer.c:42
GWEN_STRINGLISTENTRY * GWEN_StringList_FirstEntry(const GWEN_STRINGLIST *sl)
Definition: stringlist.c:390
void GWB_Project_AddFile(GWB_PROJECT *project, GWB_FILE *file)
Definition: project.c:219
const char * GWEN_StringListEntry_Data(const GWEN_STRINGLISTENTRY *se)
Definition: stringlist.c:406
const char * GWB_Project_GetGivenOption(const GWB_PROJECT *project, const char *name)
Definition: project.c:399
void GWB_Project_SetVersion(GWB_PROJECT *project, int vMajor, int vMinor, int vPatchlevel, int vBuild, const char *vTag)
Definition: project.c:96
int GWB_Project_GetVersionPatchlevel(const GWB_PROJECT *project)
Definition: project.c:122
void GWBUILD_Debug_PrintValue(const char *sName, const char *sValue, int indent)
Definition: gwenbuild.c:225
void GWEN_StringList_free(GWEN_STRINGLIST *sl)
Definition: stringlist.c:62
GWB_FILE_LIST2 * GWB_Project_GetFileList(const GWB_PROJECT *project)
Definition: project.c:205
void GWB_Project_SetSoVersion(GWB_PROJECT *project, int vCurrent, int vAge, int vRevision)
Definition: project.c:143
const char * GWB_Project_GetProjectName(const GWB_PROJECT *project)
Definition: project.c:77
void GWB_Project_AddOption(GWB_PROJECT *project, GWB_OPTION *option)
Definition: project.c:348
void GWB_Project_SetGivenOptionList(GWB_PROJECT *project, GWB_KEYVALUEPAIR_LIST *kvpList)
Definition: project.c:381
#define GWEN_NEW_OBJECT(typ, varname)
Definition: memory.h:55
void GWB_Project_ClearDefineList(GWB_PROJECT *project)
Definition: project.c:331
struct GWB_TARGET GWB_TARGET
Definition: target.h:17
void GWBUILD_Debug_PrintOptionList(const char *sName, const GWB_OPTION_LIST *optionList, int indent)
Definition: gwenbuild.c:388
int GWB_Project_GetSoVersionRevision(const GWB_PROJECT *project)
Definition: project.c:166
void GWB_Context_Tree2_Dump(const GWB_CONTEXT *ctx, int indent)
Definition: context.c:624
int GWB_Project_GetVersionMajor(const GWB_PROJECT *project)
Definition: project.c:108
void GWBUILD_Debug_PrintKvpList(const char *sName, const GWB_KEYVALUEPAIR_LIST *kvpList, int indent)
Definition: gwenbuild.c:247
void GWB_Project_toXml(const GWB_PROJECT *project, GWEN_XMLNODE *xmlNode)
Definition: project.c:420
struct GWEN_STRINGLISTSTRUCT GWEN_STRINGLIST
Definition: stringlist.h:56
void GWBUILD_Debug_PrintFileList2(const char *sName, const GWB_FILE_LIST2 *fileList2, int indent)
Definition: gwenbuild.c:334
void GWB_Project_SetGivenOption(GWB_PROJECT *project, const char *name, const char *value)
Definition: project.c:389
static void _writeFileFlagsToXml(uint32_t flags, GWEN_XMLNODE *xmlNode, const char *varName)
Definition: project.c:473
GWEN_STRINGLIST * GWEN_StringList_fromString(const char *str, const char *delimiters, int checkDouble)
Definition: stringlist.c:746
void GWEN_Buffer_free(GWEN_BUFFER *bf)
Definition: buffer.c:89
const char * GWB_Target_GetId(const GWB_TARGET *target)
Definition: target.c:109
struct GWEN_BUFFER GWEN_BUFFER
A dynamically resizeable text buffer.
Definition: buffer.h:38
GWB_TARGET * GWB_Project_GetTargetById(const GWB_PROJECT *project, const char *id)
Definition: project.c:248
static uint32_t _readFlagsFromChar(const char *flagsAsText)
Definition: buildctx_xml.c:238
#define GWB_PROJECT_FLAGS_CONFIG_H
Definition: project.h:27
GWB_KEYVALUEPAIR * GWB_KeyValuePair_new(const char *key, const char *value)
Definition: keyvaluepair.c:34
#define DBG_ERROR(dbg_logger, format, args...)
Definition: debug.h:97
void GWB_File_List2_WriteXml(const GWB_FILE_LIST2 *fileList, GWEN_XMLNODE *xmlNode, const char *groupName)
Definition: file.c:670
GWB_BUILD_CMD_LIST * GWB_Project_GetExplicitBuildList(const GWB_PROJECT *project)
Definition: project.c:406
void GWBUILD_Debug_PrintBuilderList2(const char *sName, const GWB_BUILDER_LIST2 *builderList2, int indent, int fullDump)
Definition: gwenbuild.c:409
int GWB_Project_GetVersionMinor(const GWB_PROJECT *project)
Definition: project.c:115
GWB_FILE * GWB_Project_GetFileByPathAndName(const GWB_PROJECT *project, const char *folder, const char *fname)
Definition: project.c:212
void GWB_Project_SetProjectName(GWB_PROJECT *project, const char *s)
Definition: project.c:84
GWB_FILE * GWB_File_List2_GetFileByPathAndName(const GWB_FILE_LIST2 *fileList, const char *folder, const char *fname)
Definition: file.c:353
GWEN_STRINGLISTENTRY * GWEN_StringListEntry_Next(const GWEN_STRINGLISTENTRY *se)
Definition: stringlist.c:398
struct GWB_KEYVALUEPAIR GWB_KEYVALUEPAIR
Definition: keyvaluepair.h:19
struct GWB_BUILD_CMD GWB_BUILD_CMD
Definition: buildcmd.h:20
struct GWB_BUILDER GWB_BUILDER
Definition: builder.h:17
const char * GWB_KeyValuePair_List_GetValue(const GWB_KEYVALUEPAIR_LIST *kvpList, const char *key)
Definition: keyvaluepair.c:132
GWB_OPTION * GWB_Project_GetOptionById(const GWB_PROJECT *project, const char *optionId)
Definition: project.c:355
uint32_t GWB_Project_GetFlags(const GWB_PROJECT *project)
Definition: project.c:173
GWB_KEYVALUEPAIR_LIST * GWB_Project_GetGivenOptionList(const GWB_PROJECT *project)
Definition: project.c:374
GWB_KEYVALUEPAIR * GWB_KeyValuePair_List_GetFirstByKey(const GWB_KEYVALUEPAIR_LIST *kvpList, const char *key)
Definition: keyvaluepair.c:144
void GWB_Project_AddTarget(GWB_PROJECT *project, GWB_TARGET *target)
Definition: project.c:241
void GWB_Project_SetDefineQuoted(GWB_PROJECT *project, const char *name, const char *value)
Definition: project.c:316
struct GWENBUILD GWENBUILD
Definition: gwenbuild.h:15
void GWB_Context_free(GWB_CONTEXT *ctx)
Definition: context.c:93
int GWB_Project_GetSoVersionCurrent(const GWB_PROJECT *project)
Definition: project.c:152
void GWB_Project_AddBuilder(GWB_PROJECT *project, GWB_BUILDER *builder)
Definition: project.c:284
struct GWEN__XMLNODE GWEN_XMLNODE
Definition: xml.h:156
GWB_CONTEXT * GWB_Project_GetRootContext(const GWB_PROJECT *project)
Definition: project.c:226
void GWB_BuildCmd_List_WriteXml(const GWB_BUILD_CMD_LIST *cmdList, GWEN_XMLNODE *xmlNode, const char *groupName)
Definition: buildcmd.c:530
int GWEN_Buffer_AppendString(GWEN_BUFFER *bf, const char *buffer)
Definition: buffer.c:989
const char * GWB_Option_GetId(const GWB_OPTION *option)
Definition: option.c:63
int GWB_Project_GetSoVersionAge(const GWB_PROJECT *project)
Definition: project.c:159
void GWEN_XMLNode_AddChild(GWEN_XMLNODE *n, GWEN_XMLNODE *child)
Definition: xml.c:423
void GWEN_XMLNode_SetIntValue(GWEN_XMLNODE *n, const char *name, int value)
Definition: xml.c:940