Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 721078 - app-arch/pbzip2-1.1.12: with clang: pbzip2.cpp: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
Summary: app-arch/pbzip2-1.1.12: with clang: pbzip2.cpp: error: invalid suffix on lite...
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Lars Wendler (Polynomial-C)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-05-05 11:31 UTC by Frederik Pfautsch
Modified: 2020-05-08 23:22 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
app-arch:pbzip2 build log (app-arch:pbzip2-1.1.12:20200505-105145.log,4.67 KB, text/x-log)
2020-05-05 11:31 UTC, Frederik Pfautsch
Details
emerge info (emerge.info,5.75 KB, application/x-info)
2020-05-05 11:32 UTC, Frederik Pfautsch
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Frederik Pfautsch 2020-05-05 11:31:07 UTC
Created attachment 636186 [details]
app-arch:pbzip2 build log

From the compile log:

<...>
clang++ -O2 -pipe -fsanitize=safe-stack -fuse-ld=ld -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -DUSE_STACKSIZE_CUSTOMIZATION -pthread -D_POSIX_PTHREAD_SEMANTICS  -fsanitize=safe-stack pbzip2.cpp BZ2StreamScanner.cpp ErrorContext.cpp -o pbzip2 -lbz2 -lpthread
pbzip2.cpp:1226:75: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
                                fprintf(stderr, "pbzip2:  *WARNING: Compressed block size is large [%"PRIuMAX" bytes].\n",
                                                                                                      ^
                                                                                                       
pbzip2.cpp:1836:39: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
                fprintf(stderr, "    Output Size: %"PRIuMAX" bytes\n", (uintmax_t)CompressedSize);
                                                    ^
                                                     
pbzip2.cpp:2079:39: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
                fprintf(stderr, "    Output Size: %"PRIuMAX" bytes\n", (uintmax_t)CompressedSize);
                                                    ^
                                                     
pbzip2.cpp:2814:80: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
                fprintf(stderr, "pbzip2: *ERROR: Could not initialize (OutputBuffer); size=%"PRIuMAX"!  Aborting...\n", (uintmax_t)size);
                                                                                             ^
                                                                                              
pbzip2.cpp:4120:41: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
                                fprintf(stderr, "     Input Size: %"PRIuMAX" bytes\n", (uintmax_t)InFileSize);
                                                                    ^
                                                                     
pbzip2.cpp:4242:65: error: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wreserved-user-defined-literal]
                                        fprintf(stderr, "*Warning* Max memory limit increased to %"PRIuMAX" MB to support %d CPUs\n", (uintmax_t)((NumBufferedBlocksMax + (numCPU * 2)) * blockSize)/100000...
                                                                                                   ^
                                                                                                    <...>

Builds fine when using gcc instead of clang.

clang --version:
clang version 9.0.1 
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/9/bin

gcc --version:
gcc (Gentoo 9.2.0-r2 p3) 9.2.0
Copyright (C) 2019 Free Software Foundation, Inc.
Comment 1 Frederik Pfautsch 2020-05-05 11:32:46 UTC
Created attachment 636188 [details]
emerge info