- PROBLEM
We use OBS to build packages in Tizen.
There is a mechanism not to rebuild if the result binary is the same.
For example, there is a dependency graph: A->B->C.
If A is modified, B would be built.
If the result RPM of B is not changed, OBS does not trigger a build of C.
To effectively use this mechanism, each packages make sure that
the result binary should be the same if the input source is the same.
This package uses __DATE__ and __TIME__ which make the result binary
is different everytime it is built.
To efficiently utilize OBS build mechanism and to modify the package
as little as possible, I propose to store this macro in .tizen.build-id
section. OBS build-compare tool does not check *.build-id section
in the binary.
Change-Id: Ic3af17799ab4fe5f06cb85e5a261033d87391bac
Signed-off-by: Junghyun Kim <jh0822.kim@samsung.com>
#define PROGRAM_NAME "gif2rgb"
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "
#define DEFAULT_DIR "T" /* TOP (North) direction. */
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "
#define PROGRAM_NAME "gifbuild"
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Eric Raymond, "
#define PROGRAM_NAME "gifclrmp"
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "
#define LINE_LEN 40
#define IMAGEWIDTH LINE_LEN*GIF_FONT_WIDTH
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "
#define DEFAULT_COLOR_GREEN 255
#define DEFAULT_COLOR_BLUE 255
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "
#define PROGRAM_NAME "giffix"
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "
#define DEFAULT_HISTO_HEIGHT 256
#define HISTO_BITS_PER_PIXEL 2 /* Size of bitmap for histogram GIF. */
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "
#define DEFAULT_OUT_NAME "GifInto.Gif"
#define DEFAULT_TMP_NAME "TempInto.XXXXXX"
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "
#define MAKE_PRINTABLE(c) (isprint(c) ? (c) : ' ')
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "
#define DEFAULT_NUM_LEVELS 16 /* Number of colors to gen the image. */
+__attribute__((__section__(".tizen.build-id")))
static char
- *VersionStr =
+ VersionStr[] =
PROGRAM_NAME
VERSION_COOKIE
" Gershon Elber, "