Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Managed C++/CLI
  4. Problems with lib file and linking

Problems with lib file and linking

Scheduled Pinned Locked Moved Managed C++/CLI
helptutorialquestion
5 Posts 2 Posters 0 Views 1 Watching
  • 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 Offline
    R Offline
    ravjak
    wrote on last edited by
    #1

    Hi all! I'm want to use my library in another project. I have compiled my lib (tmf.lib) succesfully. But when i I whant to use there a Linking error: error LNK2001: unresolved external symbol "void __cdecl tmf_close(struct TmfClass *)" (?tmf_close@@YAXPAUTmfClass@@@Z) error LNK2001: unresolved external symbol "struct TmfClass * __cdecl tmf_init(char const *)" (?tmf_init@@YAPAUTmfClass@@PBD@Z) The problem is that I've added tmf.lib to project settings library modules and copied tmf.lib and some header files to project dir. Does anyone know how to solve this problem? PS I also tryed to this similar stuff but with a very small lib containg only a few functions a every thing was ok. Pain is a weakness living the body

    I R 2 Replies Last reply
    0
    • R ravjak

      Hi all! I'm want to use my library in another project. I have compiled my lib (tmf.lib) succesfully. But when i I whant to use there a Linking error: error LNK2001: unresolved external symbol "void __cdecl tmf_close(struct TmfClass *)" (?tmf_close@@YAXPAUTmfClass@@@Z) error LNK2001: unresolved external symbol "struct TmfClass * __cdecl tmf_init(char const *)" (?tmf_init@@YAPAUTmfClass@@PBD@Z) The problem is that I've added tmf.lib to project settings library modules and copied tmf.lib and some header files to project dir. Does anyone know how to solve this problem? PS I also tryed to this similar stuff but with a very small lib containg only a few functions a every thing was ok. Pain is a weakness living the body

      I Offline
      I Offline
      ian mariano
      wrote on last edited by
      #2

      Add the project dir to the list of directories searched for libraries/headers in the IDE (Tools | Options -- find the VC++ settings)

      Ian Mariano - http://www.ian-space.com/
      "We are all wave equations in the information matrix of the universe" - me

      R 1 Reply Last reply
      0
      • I ian mariano

        Add the project dir to the list of directories searched for libraries/headers in the IDE (Tools | Options -- find the VC++ settings)

        Ian Mariano - http://www.ian-space.com/
        "We are all wave equations in the information matrix of the universe" - me

        R Offline
        R Offline
        ravjak
        wrote on last edited by
        #3

        hmm! not working any other ideas. I think its something with precompiled headers.:~ . Pain is a weakness living the body

        R 1 Reply Last reply
        0
        • R ravjak

          hmm! not working any other ideas. I think its something with precompiled headers.:~ . Pain is a weakness living the body

          R Offline
          R Offline
          ravjak
          wrote on last edited by
          #4

          And its not working after I added all header and source files to project. All the time the same error!!! Pain is a weakness living the body

          1 Reply Last reply
          0
          • R ravjak

            Hi all! I'm want to use my library in another project. I have compiled my lib (tmf.lib) succesfully. But when i I whant to use there a Linking error: error LNK2001: unresolved external symbol "void __cdecl tmf_close(struct TmfClass *)" (?tmf_close@@YAXPAUTmfClass@@@Z) error LNK2001: unresolved external symbol "struct TmfClass * __cdecl tmf_init(char const *)" (?tmf_init@@YAPAUTmfClass@@PBD@Z) The problem is that I've added tmf.lib to project settings library modules and copied tmf.lib and some header files to project dir. Does anyone know how to solve this problem? PS I also tryed to this similar stuff but with a very small lib containg only a few functions a every thing was ok. Pain is a weakness living the body

            R Offline
            R Offline
            ravjak
            wrote on last edited by
            #5

            Its working. The problem was with compiler params lib was compiled as ansi C and my projekt is in VC++ :-). After compiling lib in c++ compiler everything is OK:) Pain is a weakness living the body

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups