Bug 60689 - replace SUPD variable ...
Summary: replace SUPD variable ...
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
4.0.0.3 release
Hardware: Other All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:4.4.0
Keywords: difficultyBeginner, easyHack, skillCpp, topicCleanup
Depends on:
Blocks:
 
Reported: 2013-02-11 20:31 UTC by Michael Meeks
Modified: 2016-02-18 16:37 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Meeks 2013-02-11 20:31:40 UTC
The 'SUPD' variable mangles to something like '360' for LibreOffice 3.6.0 - but this is a pretty horribly limited scheme - and we can do better.

These days we have a header:

#include <config/config_version.h>

That includes things like:

#define LIBO_VERSION_MAJOR 4
#define LIBO_VERSION_MINOR 1
#define LIBO_VERSION_MICRO 0
#define LIBO_VERSION_PATCH 0

Which we should use instead.

It would be great to rid the code and configure.in etc. of all instances of SUPD everywhere.

Thanks :-)
Comment 1 Rashid Khan 2013-02-16 18:05:06 UTC
Hey,

I would be interested in doing this clean up. This would be my first contribution to open source, if at all possible. Can I get more information on how to proceed on this bug?

Thanks

Rashid
Comment 2 Michael Meeks 2013-02-16 21:59:09 UTC
Hi Rashid - you need to read my comment which contains everything you need.

git grep 'SUPD'

and read around the code / instances of its use - it is a pre-processor define.

Then read the config/config_version.h header - then consider how to migrate away from SUPD everywhere :-)

A chunk of code-reading is necessary before almost any hack :-)
Comment 3 Marcos Souza 2013-04-17 14:33:20 UTC
Hi Rashid,

Are you still working on this bug?

If not, I can work on this or let this to someone work in our HackDay in May, 18 :)
Comment 4 Marcos Souza 2013-04-17 15:12:30 UTC
Michael,

while doing
git grep 'SUPD' | grep -w 'SUPD'

I get a entry in doxygen config file
solenv/inc/doxygen.cfg:                         SUPD=300 \

What we can do in this case?

And, in configure.ac we define -DSUPD=$(UPD)

And UPD is

UPD="${LIBO_VERSION_MAJOR}${LIBO_VERSION_MINOR}0"

And we have the
SOURCEVERSION="OOO$UPD"

That is used just once in the exported variable as
export WORK_STAMP=@SOURCEVERSION@

That it's used in two perl files:
solenv/bin/modules/installer/control.pm:        WORK_STAMP
solenv/bin/modules/installer/environment.pm:    $installer::globals::build = $environment->{'WORK_STAMP'};

The first file take the value of the env variable

I don't speak perl, but it seems that the second one uses the value of the same env variable.

What we can do in these cases?

(Sorry about all these questions :) )
Comment 5 Björn Michaelsen 2013-08-26 20:18:35 UTC
SUPD is mostly gone:

 http://opengrok.libreoffice.org/search?q=SUPD&project=core&defs=&refs=&path=&hist=

@Michael: Can we close this and if not, can you answer the questions from Comment 4?
Comment 6 Michael Meeks 2013-08-27 03:42:04 UTC
Well - the task is not yet complete; wrt. answering the questions: the goal is to remove SUPD and other versioning info that is not covered in config_version.h

I see no non-C/C++ code using SUPD in master - so, there should be no big issue here. The doxygen.cfg line can be removed without issues I think.

SUPD=420 for 4.2.0 - should be easy to make that work with the version macros.
Comment 7 Björn Michaelsen 2013-10-04 18:48:04 UTC
adding LibreOffice developer list as CC to unresolved EasyHacks for better visibility.

see e.g. http://nabble.documentfoundation.org/minutes-of-ESC-call-td4076214.html for details
Comment 8 Robinson Tryon (qubit) 2013-10-23 16:45:42 UTC
Removing comma from whiteboard (please use a space to delimit values in this field)
https://wiki.documentfoundation.org/QA/Bugzilla/Fields/Whiteboard#Getting_Started
Comment 10 Mike §chinagl 2015-01-22 11:21:16 UTC
This bug fix comes with LibreOffice 4.4 and is mentioned in the release notes (https://wiki.documentfoundation.org/ReleaseNotes/4.4)
Comment 11 Robinson Tryon (qubit) 2015-12-15 23:57:26 UTC
Migrating Whiteboard tags to Keywords: (EasyHack DifficultyBeginner SkillCpp TopicCleanup)
[NinjaEdit]
Comment 12 Robinson Tryon (qubit) 2016-02-18 16:37:30 UTC
Remove LibreOffice Dev List from CC on EasyHacks
(curtailing excessive email to list)
[NinjaEdit]