The plugin should be placed in a new plugins/epan/foo directory which should contain at least the following files:
The README can be brief but it should provide essential information relevant to developers and users. Optionally AUTHORS and ChangeLog files can be added. Optionally you can add your own plugin.rc.in.
And of course the source and header files for your dissector.
Examples of these files can be found in plugins/epan/gryphon.
For your plugins/epan/foo/CMakeLists.txt file, see the corresponding file in plugins/epan/gryphon. Replace all occurrences of "gryphon" in those files with "foo" and add your source files to the DISSECTOR_SRC variable.