View Issue Details

IDProjectCategoryView StatusLast Update
0001128bareos-coreapipublic2019-11-03 18:52
Reporterrjung Assigned To 
Status newResolutionopen 
PlatformSolaris10OSSolarisOS Version10
Product Version18.2.6 
Summary0001128: Compilation error due to existing symbol round()
DescriptionActually version is 18.4.1 but that doesn't exist in the mantis version dropdown.

File core/src/lib/ defines a function round() which leads to a compilation error on Solaris 10 Sparc, because that symbol already exists. Since the new round(9 is static, obne can rename it, eg. to roundit. The following patch helps:

--- core/src/lib/ Fri Sep 28 10:30:36 2018
+++ core/src/lib/ Sun Nov 3 18:07:19 2019
@@ -618,7 +618,7 @@
    return result;

-static int64_t round(LDOUBLE value)
+static int64_t roundit(LDOUBLE value)
    int64_t intpart;

@@ -685,7 +685,7 @@
    /* We "cheat" by converting the fractional part to integer by
     * multiplying by a factor of 10
- fracpart = round((pow10(max)) * (ufvalue - intpart));
+ fracpart = roundit((pow10(max)) * (ufvalue - intpart));

    if (fracpart >= pow10(max)) {
Steps To ReproduceCompile on Solaris 10 Sparc.
Tagscompile solaris
bareos-master: impact
bareos-master: action
bareos-19.2: impact
bareos-19.2: action
bareos-18.2: impact
bareos-18.2: action
bareos-17.2: impact
bareos-17.2: action
bareos-16.2: impact
bareos-16.2: action
bareos-15.2: impact
bareos-15.2: action
bareos-14.2: impact
bareos-14.2: action
bareos-13.2: impact
bareos-13.2: action
bareos-12.4: impact
bareos-12.4: action


There are no notes attached to this issue.

Issue History

Date Modified Username Field Change
2019-11-03 18:52 rjung New Issue
2019-11-03 18:52 rjung Tag Attached: compile solaris