First time here? Check out the FAQ!
THIS IS A TEST INSTANCE. Feel free to ask and answer questions, but take care to avoid triggering too many notifications.
0

CMake Error: CMake can not determine linker language for target:

Hi,

I am trying to create wireshark dissector plugin. I have referred README.plugins file. I have to create plugin using custom extension. I followed all the steps mentioned in README.plugins upto 3.1. But i am getting error as follows,

-- Configuring done
CMake Error at cmake/modules/WiresharkPlugin.cmake:32 (add_library):
  Cannot find source file:

    packet-75f_wirless.C

  Tried extensions .c .C .c++ .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp
  .hxx .in .txx
Call Stack (most recent call first):
  plugins/75f_wireless/CMakeLists.txt:55 (add_plugin_library)

CMake Error: CMake can not determine linker language for target: 75f_wirless
-- Generating done
-- Build files have been written to: C:/Development/wireshark

So let me know how can remove this linker error.

Thanks, Nilesh

anonymous user
asked 2018-01-25 20:53:56 +0000
Guy Harris's avatar
19.9k
Guy Harris
updated 2018-01-25 22:37:37 +0000
edit flag offensive 0 remove flag close merge delete

Comments

So what is the name of your source code file?

Guy Harris's avatar Guy Harris (2018-01-25 22:38:25 +0000) edit

Source code file: - packet-75f_wireless.C plugin folder name: - 75f_wireless

nileshbhadule's avatar nileshbhadule (2018-01-26 04:54:26 +0000) edit

Which version of Wireshark are you attempting to build with?

grahamb's avatar grahamb (2018-01-26 10:32:29 +0000) edit

Its 2.4.2.

nileshbhadule's avatar nileshbhadule (2018-01-26 13:13:29 +0000) edit

Is the capital C causing grief?

Anders's avatar Anders (2018-01-26 13:47:21 +0000) edit
add a comment see more comments

2 Answers

0

Note the spelling of the filename in error message, assuming it was correctly transcribed:

Cannot find source file:
    packet-75f_wirless.C

Do you have a typo in the plugin CMakeLists.txt, misspelling the source file name?

grahamb's avatar
23.8k
grahamb
answered 2018-01-26 13:28:47 +0000
edit flag offensive 0 remove flag delete link

Comments

It was incorrect spelling. So it got resolved.

Thank you very much.

Thanks, Nilesh.

nileshbhadule's avatar nileshbhadule (2018-01-26 16:56:34 +0000) edit

I've fixed up the comments and converted it to an answer with your response. Please accept the answer to let others know what the problem was by clicking the checkmark next to the answer.

grahamb's avatar grahamb (2018-01-26 17:43:02 +0000) edit
add a comment see more comments
0

Use the statement add_plugin_library(75f_wireless) or add_plugin_library(75f_wireless epan) for Wireshark 2.4 and Wireshark developmen version respecitvely.

Jaap's avatar
13.7k
Jaap
answered 2018-01-26 12:20:12 +0000
edit flag offensive 0 remove flag delete link

Comments

Are we missing a docs update for the recent changes?

grahamb's avatar grahamb (2018-01-26 12:33:22 +0000) edit

add_plugin_library call is already there in CMakeList.txt in plugin/75f_wireless folder. I have followed gryphon example as mentioned in README.plugins. Thanks, Nilesh

nileshbhadule's avatar nileshbhadule (2018-01-26 13:15:42 +0000) edit

@grahamb: I hope not, I've worked on README.plugins in master quite a bit.

@nileshbhadule: Sounds oke. Could you post (on pastebin or something) a directory listing of your plugin directoryand the contents of your plugins CMakeLists.txt file.?

Jaap's avatar Jaap (2018-01-26 15:23:27 +0000) edit
add a comment see more comments

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss.

Add Answer