kou commented on code in PR #39524:
URL: https://github.com/apache/arrow/pull/39524#discussion_r1445651705
##########
cpp/cmake_modules/ThirdpartyToolchain.cmake:
##########
@@ -4846,7 +4846,8 @@ macro(build_awssdk)
set(AWS_LC_C_FLAGS ${EP_C_FLAGS})
string(APPEND AWS_LC_C_FLAGS " -Wno-error=overlength-strings
-Wno-error=pedantic")
# Link time optimization is causing trouble like #34349
- string(REPLACE "-flto=auto" "" AWS_LC_C_FLAGS "${AWS_LC_C_FLAGS}")
+ # "-flto" and "-flto=10" are added by R with --enable/use-lto see #39523
+ string(REPLACE "-flto[^ ]*" "" AWS_LC_C_FLAGS "${AWS_LC_C_FLAGS}")
Review Comment:
OpenSSL 1 and 3 are mixed?
##########
cpp/cmake_modules/ThirdpartyToolchain.cmake:
##########
@@ -4846,7 +4846,8 @@ macro(build_awssdk)
set(AWS_LC_C_FLAGS ${EP_C_FLAGS})
string(APPEND AWS_LC_C_FLAGS " -Wno-error=overlength-strings
-Wno-error=pedantic")
# Link time optimization is causing trouble like #34349
- string(REPLACE "-flto=auto" "" AWS_LC_C_FLAGS "${AWS_LC_C_FLAGS}")
+ # "-flto" and "-flto=10" are added by R with --enable/use-lto see #39523
+ string(REPLACE "-flto[^ ]*" "" AWS_LC_C_FLAGS "${AWS_LC_C_FLAGS}")
Review Comment:
This warning may be related:
```text
g++ -std=gnu++17 -shared -Wall -pedantic -flto -fpic
-L/opt/R-devel/lib/R/lib -L/usr/local/lib -o arrow.so RTasks.o altrep.o array.o
array_to_vector.o arraydata.o arrowExports.o bridge.o buffer.o chunkedarray.o
compression.o compute-exec.o compute.o config.o csv.o dataset.o datatype.o
expression.o extension-impl.o feather.o field.o filesystem.o io.o json.o
memorypool.o message.o parquet.o r_to_arrow.o recordbatch.o recordbatchreader.o
recordbatchwriter.o safe-call-into-r-impl.o scalar.o schema.o symbols.o table.o
threadpool.o type_infer.o
-L/arrow/r/check/arrow.Rcheck/00_pkg_src/arrow/libarrow/arrow-14.0.1.100000264/lib
-L/usr/lib/lib/x86_64-linux-gnu -L/usr/lib/lib -larrow_dataset -lparquet
-larrow_acero -larrow -larrow_bundled_dependencies
/usr/lib/x86_64-linux-gnu/libbz2.so -lbrotlidec -lbrotlienc -lz -lzstd -lcurl
-lssl -lcrypto -L/opt/R-devel/lib/R/lib -lR
lto-wrapper: warning: Extra option to ‘-Xassembler’: --noexecstack, dropping
all ‘-Xassembler’ and ‘-Wa’ options.
/tmp/RtmpoBLPp7/working_dir/RtmpRJJbvI/file77c6759da9b/aws_lc_ep-install/include/openssl/err.h:176:
warning: type of ‘ERR_get_error’ does not match original declaration
[-Wlto-type-mismatch]
/usr/include/openssl/err.h:417: note: return value type mismatch
417 | unsigned long ERR_get_error(void);
|
/usr/include/openssl/err.h:417: note: type ‘long unsigned int’ should match
type ‘uint32_t’
/usr/include/openssl/err.h:417: note: ‘ERR_get_error’ was previously
declared here
/usr/include/openssl/err.h:417: note: code may be misoptimized unless
‘-fno-strict-aliasing’ is used
lto-wrapper: warning: using serial compilation of 128 LTRANS jobs
lto-wrapper: note: see the ‘-flto’ option documentation for more information
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]