Opened 3 years ago

Closed 3 years ago

#4451 closed defect (invalid)

Hardcoded local paths in precompiled libadblockplus

Reported by: asmirnov Assignee: asmirnov
Priority: P2 Milestone:
Module: Libadblockplus Keywords:
Cc: rjeschke, fhd, sergz Blocked By:
Blocking: #4399 Platform: Android
Ready: yes Confidential: no
Tester: Unknown Verified working: no
Review URL(s):

Description

Environment

While integrating libadblockplus-android into our partners product we're having link issue.
Some paths like "/home/rjeschke/develop/android/ndk/sources/cxx-stl/llvm-libc++/../../android/support/include" can be found in precompiled libadblockplus.a files

Relates to libadblockplus-binaries repo

How to reproduce

  1. run ".gradlew assemble"
  2. make sure build failed, link error reported (see attached file)

Attachments (1)

build.log (27.1 KB) - added by asmirnov 3 years ago.
build log

Download all attachments as: .zip

Change History (9)

Changed 3 years ago by asmirnov

build log

comment:1 Changed 3 years ago by asmirnov

  • Cc sergz added

comment:2 Changed 3 years ago by asmirnov

  • Blocking 4399 added

comment:3 Changed 3 years ago by asmirnov

after recompilation on my dev machine i'm still having local dev paths in libadblockplus.a file. the difference is that local paths are mine not rene's

comment:4 Changed 3 years ago by sergz

libadblockplus.a does not have any paths. .a file is supposed to be a simple archive (see ar) of object files (.o). Object files are supposed to be linked, there are simply no paths in our case.

The path "/home/rjeschke/develop/android/ndk/sources/cxx-stl/llvm-libc++/../../android/support/include" seems a headers search path, I guess, it's built from hard-coded path parts somewhere in files for gradle/ant/maven/make/etc.

comment:5 Changed 3 years ago by asmirnov

MBA-Anton:libadblockplus-android.chinese asmirnov$ grep -Hrn rjeschke .
Binary file ./libadblockplus-android/build/intermediates/binaries/debug/obj/armeabi-v7a/libadblockplus-jni.so matches
Binary file ./libadblockplus-android/build/intermediates/binaries/debug/obj/x86/libadblockplus-jni.so matches
Binary file ./libadblockplus-android/build/intermediates/binaries/release/obj/armeabi-v7a/libadblockplus-jni.so matches
Binary file ./libadblockplus-android/build/intermediates/binaries/release/obj/x86/libadblockplus-jni.so matches
Binary file ./libadblockplus-android/jni/libadblockplus-binaries/android_armeabi-v7a/libadblockplus.a matches
Binary file ./libadblockplus-android/jni/libadblockplus-binaries/android_x86/libadblockplus.a matches

no text "rjes" in any config files

Last edited 3 years ago by asmirnov (previous) (diff)

comment:6 Changed 3 years ago by sergz

Sorry, I've missed attached log file. These paths are simply to help to debug the compilation errors. If you include calling of strip in the building process, they will go away.
I guess the issue is that some library to link with is missed.

comment:7 Changed 3 years ago by sergz

Actually, the linker cannot find only few particular functions, so I would recommend to ensure that the version of ndk is the correct one. E.g. it seems c++_static is different.

comment:8 Changed 3 years ago by asmirnov

  • Resolution set to invalid
  • Status changed from new to closed

Having hard-coded paths is not the issue, they will be removed during "striping". Here is the actual reason: https://issues.adblockplus.org/ticket/4453

Note: See TracTickets for help on using tickets.