Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    Undefined symbols for architecture x86_64

    Cinema 4D SDK
    2
    9
    2.7k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R
      rui_mac
      last edited by

      After cleaning up all the errors that Xcode was flagging, I get this final error that I really don't know how to solve ☹

      Undefined symbols for architecture x86_64:
      "maxon::details::ModuleInfoWrapper<8132888662419880549ull>::info", referenced from:
      ___cxx_global_var_init in Patterner.o
      ___cxx_global_var_init in main.o
      ld: symbol(s) not found for architecture x86_64
      clang: error: linker command failed with exit code 1 (use -v to see invocation)

      Can anyone help me?

      1 Reply Last reply Reply Quote 0
      • r_giganteR
        r_gigante
        last edited by

        Hi rui_mac, thanks for reaching us.

        With regard to the issue reported, looks like there are missing method implementations of some classes in Patterner.cpp.
        Could you kindly provide some additional detail on what classes are used and how you're using them there?

        Last but not least where you able to compile and successfully run the Cinema 4D SDK example sets?

        Cheers, Riccardo.

        1 Reply Last reply Reply Quote 1
        • R
          rui_mac
          last edited by

          These are my #includes:

          #include "c4d.h"
          #include "c4d_symbols.h"
          #include "math.h"
          #include "Patterner.h"

          #include <fstream>
          #include <iostream>
          #include <string>

          And I'm using the ShaderData class

          1 Reply Last reply Reply Quote 0
          • R
            rui_mac
            last edited by

            Oh, and yes, I did managed to compile all the Cinema 4D SDK examples and they are all working fine.

            1 Reply Last reply Reply Quote 0
            • r_giganteR
              r_gigante
              last edited by

              Hi rui, thanks for the follow-up.

              Before providing details on what's declared inside Patterner.cpp/.h, can you confirm the project where the issue happens is created using the Project Tool? Can you also share the frameworks you're including as dependencies for this project?

              It seems like you're not adding the core.framework in the projectdefinition.txt.

              Looking forward your input, give best.
              Riccardo

              1 Reply Last reply Reply Quote 1
              • R
                rui_mac
                last edited by

                I did create the project with the Project Tool.
                My projectdefinition.txt for this particular plugin is:

                // Supported platforms - can be [Win64;OSX]
                Platform=Win64;OSX

                // Type of project - can be [Lib;DLL;App]
                Type=DLL

                // API dependencies
                APIS=image.framework;cinema.framework;mesh_misc.framework;math.framework;crypt.framework;python.framework;core.framework;command.framework

                // C4D component
                C4D=true

                stylecheck.level=0 // must be set after c4d=true

                // Custom ID
                ModuleId=com.ruimac.patterner

                But I did finally managed to compile it successfully. However, it now crashes Cinema 4D when I add the shader to a material.
                And I can't seem to find a way to track what is going wrong ☹

                1 Reply Last reply Reply Quote 0
                • R
                  rui_mac
                  last edited by

                  I honestly don't know what happened to the plugin that this post refers to, as it started compiling without error (although it hangs Cinema 4D, when I try to run it).
                  But I'm getting the same error with another one:

                  0_1547640704667_Screenshot 2019-01-16 at 12.03.09.png

                  What can be occurring, to be getting these errors?

                  1 Reply Last reply Reply Quote 0
                  • r_giganteR
                    r_gigante
                    last edited by

                    Hi rui_mac, thanks for following up.

                    But I did finally managed to compile it successfully. However, it now crashes Cinema 4D when I add the shader to a material.
                    And I can't seem to find a way to track what is going wrong ☹

                    It's unclear from your previous post what has been changed in order to make it compiling although looks like that the change you brought is leading to further issue during runtime. Can you explain what you did there to get it compiled?

                    Can you describe step by step approach the process you're using to migrate your project to R20?
                    To me looks like a systemic issue rather then something related to the specific project.

                    Best, Riccardo

                    1 Reply Last reply Reply Quote 0
                    • R
                      rui_mac
                      last edited by

                      This is really weird but after getting this error (and everything all being Ok), the way that I found to get rid of this error is to delete the xcodeproj, the props, the vcxproj and the vcxproj.filters files from the project folder, leaving just the projectdefinition.txt file there, and running the Project Tool again. Then, opening the newly created xcodeproj file, I no longer get this error and it compiles fine.

                      1 Reply Last reply Reply Quote 0
                      • First post
                        Last post