Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Issues With gnustep-base/gnustep-base Blocking World Updates
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
RandomDSdevel
n00b
n00b


Joined: 28 Feb 2022
Posts: 44
Location: Kokomo, IN, USA

PostPosted: Mon Sep 23, 2024 1:18 am    Post subject: Issues With gnustep-base/gnustep-base Blocking World Updates Reply with quote

Hardware:

  • HP ZBook 17 G6
  • Processor: Intel Core i9-9880H
  • RAM: 8 GB
  • GPU: NVIDIA Quadro T1000
  • Storage: 256 GB


Host OS:

  • Windows 11 Pro 23H2 (64-bit,) build 22631.4169
  • Windows Feature Experience Pack 1000.22700.1034.0


Host Virtualization Container:

  • Windows Subsystem for Linux 2 v2.2.4 (Windows Virtualization Platform)
  • WSLg version: 1.0.61
  • MSRDC version: 1.2.5326
  • Direct3D version: 1.611.1-81528511
  • DXCore version: 10.0.26091.1-240325-1447.ge-release


Guest OS:

  • Linux Kernel: v5.15.153.1-microsoft-standard-WSL2


Toolchains:

  • (Primary:) LLVM/Clang:

    • sys-devel/llvm-common: v18.1.8
    • sys-devel/llvm: v18.1.8-r4
    • sys-devel/llvm-toolchain-symlinks: v18-r1
    • sys-devel/clang-common: v18.1.8-r1
    • sys-devel/clang: v18.1.8
    • sys-devel/clang-toolchain-symlinks: v18
    • sys-libs/compiler-rt: v18.1.8
    • sys-libs/compiler-rt-sanitizers: v18.1.8
    • sys-devel/clang-runtime: v18.1.8
    • sys-devel/lld: v18.1.8
    • sys-devel/lld-toolchain-symlinks: v18
    • sys-libs/libcxx: v18.1.8
    • sys-libs/libcxxabi: v18.1.8
    • sys-libs/llvm-libunwind: v18.1.8
    • sys-libs/libomp: v18.1.8
    • dev-debug/lldb: v18.1.8

  • (Fallback:) GCC:

    • sys-devel/gnuconfig: v20240728
    • sys-libs/glibc: v2.40
    • sys-kernel/linux-headers: v6.10
    • sys-devel/gcc: v14.2.1_p20240817
    • sys-devel/gcc-config: v2.11
    • sys-devel/binutils: v2.43-r1
    • sys-libs/binutils-libs: v2.43-r2
    • sys-devel/binutils-config: v5.5.2

---

…So I kind of went and did something a bit dumb the weekend before last and have been poking at to debug/fix it off and on ever since. I added some stuff* to `@world` before doing a `@world` update. (Head-desks.)

(* More KDE Gear apps, specifically.)

Here's where I got stuck:

Code:
kde-apps/kde-apps-meta-24.08.0:

`--  kde-apps/kdeutils-meta-24.08.0  (>=kde-apps/kdeutils-meta-24.08.0) ~amd64

    `--  app-arch/unar-1.10.8  (app-arch/unar) amd64
     `--  gnustep-base/gnustep-base-1.30.0  (gnustep-base/gnustep-base) ~amd64
      `--  gnustep-base/gnustep-make-2.9.2  (>=gnustep-base/gnustep-make-2.6.0) ~amd64
       `--  gnustep-base/libobjc2-2.2.1  (gnustep-base/libobjc2) ~amd64
        `--  dev-cpp/robin-map-1.3.0  (dev-cpp/robin-map) amd64


Code:
… # equery uses kde-apps/kdeutils-meta
[ Legend : U - final flag setting for installation]
[        : I - package is installed with flag     ]
[ Colors : set, unset                             ]
 * Found these USE flags for kde-apps/kdeutils-meta-24.08.0:
 U I
 + - 7zip      : Install app-arch/p7zip for 7zip archive support in kde-apps/ark
 + - gpg       : Install kde-apps/kgpg which depends on kde-apps/akonadi
 + - lrz       : Install app-arch/lrzip for LRZ archive support in kde-apps/ark
 + + plasma    : Build optional KDE plasma addons
 + - rar       : Install one of app-arch/rar, app-arch/unrar or app-arch/unar for RAR archive support in kde-apps/ark
 - - webengine : Install app-editors/ghostwriter and kde-apps/kimagemapeditor, requiring dev-qt/qtwebengine


  1. `dev-cpp/robin-map` `emerge`d successfully; I haven't had any issues with it.
  2. I initially had some issues getting `gnustep-base/libobjc2` to `emerge` successfully, but then I figured out what was wrong there:

    The package's source code includes some assembly code for exception handling that Clang's integrated assembly doesn't support and chokes on. Creating a new environment that adds `-fno-integrated-as` to a `COMMON_FLAGS` variable that gets expanded in and added inside `CFLAGS` and `CXXFLAGS` fixed the build. (Don't enable LTO, though; that breaks the build.)
  3. `gnustep-base/gnustep-make` then `emerge`d successfully.
  4. `gnustep-base/gnustep-base` won't `emerge` for me. The specific error I'm seeing is:

    Code:
    … # emerge --verbose --update --oneshot --newuse --changed-slot=y --with-bdeps=y gnustep-base/gnustep-base

    These are the packages that would be merged, in order:

    Calculating dependencies  .... done!
    Dependency resolution took 7.14 s (backtrack: 0/20).

    [ebuild  N     ] gnustep-base/gnustep-base-1.30.0:0/1.30::gentoo  USE="gnutls iconv icu libffi zeroconf -debug -doc" 0 KiB

    Total: 1 package (1 new), Size of downloads: 0 KiB

    >>> Verifying ebuild manifests


    >>> Emerging (1 of 1) gnustep-base/gnustep-base-1.30.0::gentoo
     * gnustep-base-1.30.0.tar.gz BLAKE2B SHA512 size ;-) ...                [ ok ]
    >>> Unpacking source...
    >>> Unpacking gnustep-base-1.30.0.tar.gz to /var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work
    >>> Source unpacked in /var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work
    >>> Preparing source in /var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0 ...
    Cleaning paths from GNUmakefile ...

    Applying gnustep-base-1.26.0-no_compress_man.patch ...

    >>> Source prepared.
    >>> Configuring source in /var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0 ...
    ./configure --prefix=/usr --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --datarootdir=/usr/share --docdir=/usr/share/doc/gnustep-base-1.30.0 --htmldir=/usr/share/doc/gnustep-base-1.30.0/html --libdir=/usr/lib64 --enable-libffi --disable-ffcall --with-ffi-include=/usr/lib64/libffi/include --enable-tls --enable-iconv --enable-icu --enable-zeroconf --with-xml-prefix=/usr --with-gmp-include=/usr/include --with-gmp-library=/usr/lib64 --with-default-config=/etc/GNUstep/GNUstep.conf

    checking the Objective-C runtime... GNU

    clang NSBlocks.m -c \
          -MMD -MP -Wall -Wdeclaration-after-statement -DGNUSTEP -DGNUSTEP_BASE_LIBRARY=1 -DGNU_RUNTIME=1 -DGNUSTEP_BASE_LIBRARY=1 -fno-strict-aliasing -fexceptions -fobjc-exceptions -D_NATIVE_OBJC_EXCEPTIONS -pthread -fPIC -Wall -DGSWARN -DGSDIAGNOSE -Wno-import -march=native -mtune=native -O2 -pipe -flto=thin -fobjc-runtime=gcc -fobjc-runtime=gcc -fblocks -fconstant-string-class=NSConstantString -I../. -I../ -I../../Headers -I. -I/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/GNUstep/Library/Headers -I/usr/local/include -I/usr/include -I/usr/local/include -I/usr/local/include -I/usr/include -I/usr/include -I/usr/lib64/libffi/include -I/usr/lib64/libffi/include -I/usr/include/libxml2 -I/usr/include/libxml2 -I/usr/include \
           -o obj/ObjectiveC2.obj/NSBlocks.m.o
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:89:15: error: typedef redefinition with different types
          ('void *' vs 'struct objc_property *')
       89 | typedef void *objc_property_t;
          |               ^
    /usr/include/objc/runtime.h:150:31: note: previous definition is here
      150 | typedef struct objc_property* objc_property_t;
          |                               ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:108:9: warning: '_OBJC_NULL_PTR' macro redefined
          [-Wmacro-redefined]
      108 | #define _OBJC_NULL_PTR ((void*)0)
          |         ^
    /usr/include/objc/runtime.h:216:10: note: previous definition is here
      216 | #       define _OBJC_NULL_PTR NULL
          |                ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:133:1: error: unknown type name 'Method_t'; did you mean
          'Method'?
      133 | Method * class_copyMethodList(Class cls, unsigned int *outCount);
          | ^~~~~~
          | Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:142:1: error: unknown type name 'Method_t'; did you mean
          'Method'?
      142 | Method class_getClassMethod(Class aClass, SEL aSelector);
          | ^~~~~~
          | Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:146:1: error: unknown type name 'Method_t'; did you mean
          'Method'?
      146 | Method class_getInstanceMethod(Class aClass, SEL aSelector);
          | ^~~~~~
          | Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:192:32: error: unknown type name 'Method_t'; did you mean
          'Method'?
      192 | char * method_copyArgumentType(Method method, unsigned int index);
          |                                ^~~~~~
          |                                Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:194:30: error: unknown type name 'Method_t'; did you mean
          'Method'?
      194 | char * method_copyReturnType(Method method);
          |                              ^~~~~~
          |                              Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:196:37: error: unknown type name 'Method_t'; did you mean
          'Method'?
      196 | void method_exchangeImplementations(Method m1, Method m2);
          |                                     ^~~~~~
          |                                     Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:196:48: error: unknown type name 'Method_t'; did you mean
          'Method'?
      196 | void method_exchangeImplementations(Method m1, Method m2);
          |                                                ^~~~~~
          |                                                Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:198:29: error: unknown type name 'Method_t'; did you mean
          'Method'?
      198 | void method_getArgumentType(Method method, unsigned int index, char *dst, size_t dst_len);
          |                             ^~~~~~
          |                             Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:200:30: error: unknown type name 'Method_t'; did you mean
          'Method'?
      200 | IMP method_getImplementation(Method method);
          |                              ^~~~~~
          |                              Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:202:20: error: unknown type name 'Method_t'; did you mean
          'Method'?
      202 | SEL method_getName(Method method);
          |                    ^~~~~~
          |                    Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:204:38: error: unknown type name 'Method_t'; did you mean
          'Method'?
      204 | unsigned method_getNumberOfArguments(Method method);
          |                                      ^~~~~~
          |                                      Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:206:27: error: unknown type name 'Method_t'; did you mean
          'Method'?
      206 | void method_getReturnType(Method method, char *dst, size_t dst_len);
          |                           ^~~~~~
          |                           Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:208:37: error: unknown type name 'Method_t'; did you mean
          'Method'?
      208 | const char * method_getTypeEncoding(Method method);
          |                                     ^~~~~~
          |                                     Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    In file included from NSBlocks.m:19:
    ../../Headers/ObjectiveC2/objc/runtime.h:210:30: error: unknown type name 'Method_t'; did you mean
          'Method'?
      210 | IMP method_setImplementation(Method method, IMP imp);
          |                              ^~~~~~
          |                              Method
    ../../Headers/ObjectiveC2/objc/runtime.h:84:17: note: expanded from macro 'Method'
       84 | #       define Method Method_t
          |                       ^
    /usr/include/objc/runtime.h:126:29: note: 'Method' declared here
      126 | typedef struct objc_method *Method;
          |                             ^
    NSBlocks.m:27:26: warning: tentative definition of variable with internal linkage has incomplete
          non-array type 'struct objc_class' [-Wtentative-definition-incomplete-type]
       27 | static struct objc_class _NSConcreteGlobalBlockMeta;
          |                          ^
    /usr/include/objc/runtime.h:84:16: note: forward declaration of 'struct objc_class'
       84 | typedef struct objc_class *Class;
          |                ^
    NSBlocks.m:28:26: warning: tentative definition of variable with internal linkage has incomplete
          non-array type 'struct objc_class' [-Wtentative-definition-incomplete-type]
       28 | static struct objc_class _NSConcreteStackBlockMeta;
          |                          ^
    /usr/include/objc/runtime.h:84:16: note: forward declaration of 'struct objc_class'
       84 | typedef struct objc_class *Class;
          |                ^
    NSBlocks.m:30:26: warning: tentative definition of variable with internal linkage has incomplete
          non-array type 'struct objc_class' [-Wtentative-definition-incomplete-type]
       30 | static struct objc_class _NSBlock;
          |                          ^
    /usr/include/objc/runtime.h:84:16: note: forward declaration of 'struct objc_class'
       84 | typedef struct objc_class *Class;
          |                ^
    NSBlocks.m:31:26: warning: tentative definition of variable with internal linkage has incomplete
          non-array type 'struct objc_class' [-Wtentative-definition-incomplete-type]
       31 | static struct objc_class _NSBlockMeta;
          |                          ^
    /usr/include/objc/runtime.h:84:16: note: forward declaration of 'struct objc_class'
       84 | typedef struct objc_class *Class;
          |                ^
    NSBlocks.m:35:8: error: unknown type name 'objc_mutex_t'
       35 | extern objc_mutex_t __objc_runtime_mutex;
          |        ^
    NSBlocks.m:42:12: error: incomplete definition of type 'struct objc_class'
       42 |   metaClass->class_pointer = superclass->class_pointer;
          |   ~~~~~~~~~^
    /usr/include/objc/runtime.h:84:16: note: forward declaration of 'struct objc_class'
       84 | typedef struct objc_class *Class;
          |                ^
    NSBlocks.m:42:40: error: incomplete definition of type 'struct objc_class'
       42 |   metaClass->class_pointer = superclass->class_pointer;
          |                              ~~~~~~~~~~^
    /usr/include/objc/runtime.h:84:16: note: forward declaration of 'struct objc_class'
       84 | typedef struct objc_class *Class;
          |                ^
    NSBlocks.m:43:12: error: incomplete definition of type 'struct objc_class'
       43 |   metaClass->super_class = superclass->class_pointer;
          |   ~~~~~~~~~^
    /usr/include/objc/runtime.h:84:16: note: forward declaration of 'struct objc_class'
       84 | typedef struct objc_class *Class;
          |                ^
    fatal error: too many errors emitted, stopping now [-ferror-limit=]
    5 warnings and 20 errors generated.
    blocks_runtime.m:92:1: warning: incompatible redeclaration of library function
          '_Block_object_assign' [-Wincompatible-library-redeclaration]
       92 | _Block_object_assign(void *destAddr, void *object, const int flags)
          | ^
    blocks_runtime.m:92:1: note: '_Block_object_assign' is a builtin with type 'void
          (void *, const void *, const int)'
    blocks_runtime.m:154:1: warning: incompatible redeclaration of library function
          '_Block_object_dispose' [-Wincompatible-library-redeclaration]
      154 | _Block_object_dispose(void *object, const int flags)
          | ^
    blocks_runtime.m:154:1: note: '_Block_object_dispose' is a builtin with type
          'void (const void *, const int)'
    gmake[5]: *** [/usr/share/GNUstep/Makefiles/rules.make:534: obj/ObjectiveC2.obj/NSBlocks.m.o] Error 1
    gmake[5]: *** Waiting for unfinished jobs....
    2 warnings generated.
    gmake[4]: *** [/usr/share/GNUstep/Makefiles/Instance/subproject.make:45: internal-subproject-all_] Error 2
    gmake[3]: *** [/usr/share/GNUstep/Makefiles/Master/rules.make:297: ObjectiveC2.all.subproject.variables] Error 2
    gmake[2]: *** [/usr/share/GNUstep/Makefiles/Master/rules.make:297: libgnustep-base.all.library.variables] Error 2
    gmake[1]: *** [/usr/share/GNUstep/Makefiles/Master/library.make:37: internal-all] Error 2
    gmake[1]: Leaving directory '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0/Source'
    make: *** [/usr/share/GNUstep/Makefiles/Master/serial-subdirectories.make:53: internal-all] Error 2
     * ERROR: gnustep-base/gnustep-base-1.30.0::gentoo failed (compile phase):
     *   emake failed
     *
     * If you need support, post the output of `emerge --info '=gnustep-base/gnustep-base-1.30.0::gentoo'`,
     * the complete build log and the output of `emerge -pqv '=gnustep-base/gnustep-base-1.30.0::gentoo'`.
     * The complete build log is located at '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/build.log'.
     * The ebuild environment file is located at '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/environment'.
     * Working directory: '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0'
     * S: '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0'

    >>> Failed to emerge gnustep-base/gnustep-base-1.30.0, Log file:

    >>>  '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/build.log'
     * Messages for package gnustep-base/gnustep-base-1.30.0:
     * ERROR: gnustep-base/gnustep-base-1.30.0::gentoo failed (compile phase):
     *   emake failed
     *
     * If you need support, post the output of `emerge --info '=gnustep-base/gnustep-base-1.30.0::gentoo'`,
     * the complete build log and the output of `emerge -pqv '=gnustep-base/gnustep-base-1.30.0::gentoo'`.
     * The complete build log is located at '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/build.log'.
     * The ebuild environment file is located at '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/environment'.
     * Working directory: '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0'
     * S: '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0'


    …Well, that isn't right. It looks to me like `gnustep-base/gnustep-base`'s build scripts are using GCC's Objective-C run-time library (detected as 'GNU') instead of the `gnustep-base/libobjc2` like they're supposed to be.


Am I doing something wrong, and if so, then what? Is there an option I can pass to `gnustep-base/gnustep-base`'s `./configure` script using `EXTRA_ECONF` to tell it where to find the correct Objecttive-C run-time library and/or which one to use? Alternatively, could I have possibly hit some kind of potential bug here?

My full logs are available as shared publicly from my personal OneDrive:

  • Most logs are [url=https://1drv.ms/f/s!AkojRV5BNJUohpF3wPCAsMLequPi4Q]here[/url].
  • A copy of all Portage environments available on my machine can be found [url=https://1drv.ms/f/s!AkojRV5BNJUohpIOwPCAsMLequPi4Q]here[/url] since the symbolic link to it that exists in the copy of my directory tree of saved `emerge` logs inside my custom WSL2 Gentoo instance appears not to have transferred over with the rest of the folder containing the logs for the failed `emerge` invocation for this issue when I copied it out to Windows and over to OneDrive.
Back to top
View user's profile Send private message
RandomDSdevel
n00b
n00b


Joined: 28 Feb 2022
Posts: 44
Location: Kokomo, IN, USA

PostPosted: Tue Oct 01, 2024 7:41 pm    Post subject: Reply with quote

Alternatively, here are the logs as a single compressed `.tar.xz` archive:

https://1drv.ms/u/s!AkojRV5BNJUojet_2yzdoXDjRcMuTA?e=9dnVxT
Back to top
View user's profile Send private message
sam_
Developer
Developer


Joined: 14 Aug 2020
Posts: 1907

PostPosted: Tue Oct 01, 2024 10:59 pm    Post subject: Reply with quote

What USE flags are set on gnustep-base/gnustep-make?

Would be worth investigating the configure script as well to see how it determines 'checking the Objective-C runtime... GNU'.
Back to top
View user's profile Send private message
RandomDSdevel
n00b
n00b


Joined: 28 Feb 2022
Posts: 44
Location: Kokomo, IN, USA

PostPosted: Tue Oct 01, 2024 11:44 pm    Post subject: Reply with quote

sam_ wrote:
What USE flags are set on gnustep-base/gnustep-make?

What I currently have set is:

Code:
… ~ # cat /etc/portage/package.use/gnustep-base
gnustep-base/gnustep-base zeroconf
… ~ # equery uses gnustep-base/gnustep-base
[ Legend : U - final flag setting for installation]
[        : I - package is installed with flag     ]
[ Colors : set, unset                             ]
 * Found these USE flags for gnustep-base/gnustep-base-1.30.0:
 U I
 - - debug    : Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful backtraces
                see https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces
 - - doc      : Add extra documentation (API, Javadoc, etc). It is recommended to enable per package instead of
                globally
 + - gnutls   : Prefer net-libs/gnutls as SSL/TLS provider (ineffective with USE=-ssl)
 + + iconv    : Enable support for the iconv character set conversion library
 + + icu      : Enable ICU (Internationalization Components for Unicode) support, using dev-libs/icu
 + - libffi   : Enable support for Foreign Function Interface library
 + - zeroconf : Support for DNS Service Discovery (DNS-SD)
Back to top
View user's profile Send private message
sam_
Developer
Developer


Joined: 14 Aug 2020
Posts: 1907

PostPosted: Wed Oct 02, 2024 1:28 am    Post subject: Reply with quote

Can you check gnustep-make, not gnustep-base?
Back to top
View user's profile Send private message
RandomDSdevel
n00b
n00b


Joined: 28 Feb 2022
Posts: 44
Location: Kokomo, IN, USA

PostPosted: Wed Oct 02, 2024 1:57 am    Post subject: Reply with quote

sam_ wrote:
Can you check gnustep-make, not gnustep-base?

`gnustep-make`'s `USE` flags are:

Code:
… ~ # equery uses gnustep-base/gnustep-make
[ Legend : U - final flag setting for installation]
[        : I - package is installed with flag     ]
[ Colors : set, unset                             ]
 * Found these USE flags for gnustep-base/gnustep-make-2.9.2:
 U I
 - - debug             : Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful
                         backtraces see https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces
 - - doc               : Add extra documentation (API, Javadoc, etc). It is recommended to enable per package instead
                         of globally
 + + libobjc2          : Enables use of the GNUstep Objective-C runtime (gnustep-base/libobjc2) with non-fragile ABI
                         and sys-devel/clang compiler
 + + native-exceptions : Enables use of the native Objective-C exception support (@try/@catch/@finally) built-in
                         objective-c exceptions with compilers that support it
Back to top
View user's profile Send private message
RandomDSdevel
n00b
n00b


Joined: 28 Feb 2022
Posts: 44
Location: Kokomo, IN, USA

PostPosted: Wed Oct 02, 2024 2:12 am    Post subject: Reply with quote

sam_ wrote:
Would be worth investigating the configure script as well to see how it determines 'checking the Objective-C runtime... GNU'.

Lines 6,034–6,057:

Code:
#--------------------------------------------------------------------
# Set Apple/Darwin/OSX/NeXT information for other tests
#--------------------------------------------------------------------
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the Objective-C runtime" >&5
$as_echo_n "checking the Objective-C runtime... " >&6; }
if test "$OBJC_RUNTIME_LIB" = "nx" -o "$OBJC_RUNTIME_LIB" = "apple"; then
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: NeXT" >&5
$as_echo "NeXT" >&6; }
  OBJCFLAGS="$OBJCFLAGS -fnext-runtime -DNeXT_RUNTIME"
elif test "$OBJC_RUNTIME_LIB" = "ng"; then
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: Next Gen" >&5
$as_echo "Next Gen" >&6; }
else
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: GNU" >&5
$as_echo "GNU" >&6; }
  if test "$CLANG_CC" = "yes"; then
    OBJCFLAGS="$OBJCFLAGS -fobjc-runtime=gcc"
  fi
fi
LIBOBJC=`gnustep-config --objc-libs`
if test "$LIBOBJC" = ""; then
  as_fn_error $? "The command 'gnustep-config --objc-libs' (provided by the gnustep-make package) returned no Objective-C library.  Unable to continue configuring without Objective-C support." "$LINENO" 5
  exit 1
fi

`OBJC_RUNTIME_LIB` is set on line 2,755.

Lines 2,751–2,755:

Code:
# If LIBRARY_COMBO is undefined, try to use gnustep-config to determine it.
if test -z "$LIBRARY_COMBO"; then
  LIBRARY_COMBO=`gnustep-config --variable=LIBRARY_COMBO 2>&5`
fi
OBJC_RUNTIME_LIB=`echo $LIBRARY_COMBO | tr '-' ' ' | awk '{print $1}'`

It looks like you can either set `LIBRARY_COMBO` before or as part of invoking the configure script or let it ask `gnustep-config` for it. Having it set properly when building `gnustep-make` so that's what `gnustep-config` reports is probably the correct way to do it, though. Here's what I get when I do that same query manually:

Code:
… ~ # gnustep-config --variable=LIBRARY_COMBO
gnu-gnu-gnu

I think that this should be `ng-gnu-gnu` instead? (From what I understand and am seeing documented in `man library-combo`, `ng` or 'Next Gen' refers to the GNUstep runtime — that is, libobjc2.) I'd expect setting the `gnustep-base/gnustep-make` package's `libobjc2` `USE` flag would handle setting this up for users already.
Back to top
View user's profile Send private message
RandomDSdevel
n00b
n00b


Joined: 28 Feb 2022
Posts: 44
Location: Kokomo, IN, USA

PostPosted: Wed Oct 02, 2024 6:43 pm    Post subject: Reply with quote

Without `EXTRA_ECONF="--with-library-combo=ng-gnu-gnu"` set, `gnustep-make`'s `configure` phase reports:

Code:
checking for library combo... gnu-gnu-gnu

With `EXTRA_ECONF="--with-library-combo=ng-gnu-gnu"` set, `gnustep-make`'s `configure` phase reports:

Code:
checking for library combo... ng-gnu-gnu

and `gnustep-config` then gives the following output:

Code:
… ~ # gnustep-config --variable=LIBRARY_COMBO
ng-gnu-gnu

as desired.

Now I'm hitting a different, weird error earlier during `configure` when building against the libobjc2, though:

Code:

checking whether objc really works... no
I don't seem to be able to use your Objective-C compiler to produce
working binaries!  Please check your Objective-C compiler installation.
If you are using gcc-3.x make sure that your compiler's libgcc_s and libobjc
can be found by the dynamic linker - usually that requires you to play
with LD_LIBRARY_PATH or /etc/ld.so.conf.
Please refer to your compiler installation instructions for more help.
configure: error: The Objective-C compiler does not work or is not installed properly.

!!! Please attach the following file when seeking support:
!!! /var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0/config.log
 * ERROR: gnustep-base/gnustep-base-1.30.0::gentoo failed (configure phase):
 *   econf failed
 *
 * Call stack:
 *               ebuild.sh, line  136:  Called src_configure
 *             environment, line 1790:  Called econf '--enable-libffi' '--disable-ffcall' '--with-ffi-include=/usr/lib64/libffi/include' '--enable-tls' '--enable-iconv' '--enable-icu' '--enable-zeroconf' '--with-xml-prefix=/usr' '--with-gmp-include=/usr/include' '--with-gmp-library=/usr/lib64' '--with-default-config=/etc/GNUstep/GNUstep.conf'
 *        phase-helpers.sh, line  719:  Called __helpers_die 'econf failed'
 *   isolated-functions.sh, line  112:  Called die
 * The specific snippet of code:
 *              die "$@"
 *
 * If you need support, post the output of `emerge --info '=gnustep-base/gnustep-base-1.30.0::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=gnustep-base/gnustep-base-1.30.0::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/environment'.
 * Working directory: '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0'
 * S: '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0'

>>> Failed to emerge gnustep-base/gnustep-base-1.30.0, Log file:

>>>  '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/build.log'

 * Messages for package gnustep-base/gnustep-base-1.30.0:

 * ERROR: gnustep-base/gnustep-base-1.30.0::gentoo failed (configure phase):
 *   econf failed
 *
 * Call stack:
 *               ebuild.sh, line  136:  Called src_configure
 *             environment, line 1790:  Called econf '--enable-libffi' '--disable-ffcall' '--with-ffi-include=/usr/lib64/libffi/include' '--enable-tls' '--enable-iconv' '--enable-icu' '--enable-zeroconf' '--with-xml-prefix=/usr' '--with-gmp-include=/usr/include' '--with-gmp-library=/usr/lib64' '--with-default-config=/etc/GNUstep/GNUstep.conf'
 *        phase-helpers.sh, line  719:  Called __helpers_die 'econf failed'
 *   isolated-functions.sh, line  112:  Called die
 * The specific snippet of code:
 *              die "$@"
 *
 * If you need support, post the output of `emerge --info '=gnustep-base/gnustep-base-1.30.0::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=gnustep-base/gnustep-base-1.30.0::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/environment'.
 * Working directory: '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0'
 * S: '/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/work/gnustep-base-1.30.0'


And, from `config.log`:

Code:

configure:8255: checking whether objc really works
configure:8275: clang -o conftest -march=native -mtune=native -O2 -pipe -flto=thin  -I/usr/local/include -I/usr/local/include -I/usr/include -I/usr/include  -x objective-c -fuse-ld=lld -rtlib=compiler-rt -unwindlib=libunwind -Wl,-O2 -Wl,--as-needed -Wl,-z,relro,-z,now -L/usr/local/lib64 -L/usr/local/lib64 -L/usr/lib64 -L/usr/lib64 conftest.c -lrt -ldl  -lpthread -fuse-ld=lld -rtlib=compiler-rt -unwindlib=libunwind -Wl,-O2 -Wl,--as-needed -Wl,-z,relro,-z,now -pthread -fexceptions -rdynamic -fobjc-runtime=gnustep-2.2 -fblocks -L/var/tmp/portage/gnustep-base/gnustep-base-1.30.0/homedir/GNUstep/Library/Libraries -L/usr/local/lib64 -L/usr/lib64 -lpthread -l:libobjc.so.4 -lm   -lpthread  >&5

ld.lld: error: undefined symbol: objc_msgSend
>>> referenced by conftest.c
>>>               /var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/conftest.lto.conftest-251b04.o:(main)

ld.lld: error: undefined symbol: __objc_load
>>> referenced by conftest.c
>>>               /var/tmp/portage/gnustep-base/gnustep-base-1.30.0/temp/conftest.lto.conftest-251b04.o:(.objcv2_load_function)
clang: error: linker command failed with exit code 1 (use -v to see invocation)
configure:8275: $? = 1
configure: program exited with status 1

configure:8291: result: no
configure:8299: error: The Objective-C compiler does not work or is not installed properly.

configure: exit 1

(Again, this is when the runtime I want, libobjc2, has been supplied explicitly and forcibly detected correctly and `gnustep-base` is getting built against it. Recall that an incorrect detection of GCC's built-in Objective-C runtime when not explicitly supplying a runtime to build against lets `emerge`ing the package get past this point and to the error I initially opened this thread to ask for help with.)

(There's also some additional information that I've omitted here, including cached input and resulting output `ocnfigure` environment variables and a dump of that `configure` test's `confdefs.h`; I can supply that, too, if need be.) I've fiddled around with the environment in use for both the `gnustep-base/gnustep-base` build and the `gnustep-base/libobjc2` and `gnustep-base/gnustep-make` builds to see if I can make this error go away, but I haven't been able to yet. All configurations I've tried so far give similar errors when I get to the point of `emerge`ing `gnustep-base/gnustep-base` again. (I can supply full build logs later.)

I'm not sure what's going on here. Is there a linkage option that's missing somewhere? Did these symbols get optimized away at some point? Do earlier stages in the chain of `emerge`ing the `gnustep-base/libobjc2`, `gnustep-base/gnustep-make`, and `gnustep-base/gnustep-base` packages save the glags and options that they were built with somewhere for later stages to refer back to later and copy in to override the flags and options that Portage is providing those later packages while `emerge`ing them? (I've poked at that last possibility a little, but I'm not entirely sure I've come to a definitive conclusion as to whether this could be a possibility yet.)

(There's one more thing I can think of to try, and that's to make sure I didn't make any copy-and-paste mistakes when initially setting my new, additional Portage environments up.)
Back to top
View user's profile Send private message
RandomDSdevel
n00b
n00b


Joined: 28 Feb 2022
Posts: 44
Location: Kokomo, IN, USA

PostPosted: Wed Oct 02, 2024 7:25 pm    Post subject: Reply with quote

No, all my Portage environments look correct.
Back to top
View user's profile Send private message
sam_
Developer
Developer


Joined: 14 Aug 2020
Posts: 1907

PostPosted: Thu Oct 03, 2024 3:33 am    Post subject: Reply with quote

Tried without LTO? It wouldn't be the first time LTO has confused a configure test.

You can also rule out the order of libraries by temporarily dropping -Wl,--as-needed from LDFLAGS.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum