Please note: We are aware of an issue affecting replies on the Arm Community forums, which may not be loading as expected.

We apologize for any inconvenience and appreciate your patience while we investigate and work to resolve the issue.

Thank you for your understanding.


This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Error: L6200E: Symbol multiply defined compiling Adam Dunkels uIP

Hello,

I get this error when compiling Adam Dunkels uIP adapted to LPC-2124 board. fs.c contains the functions to open files (fs_open) and fsdata.c contains the html code of these files. I'm completely stuck with this, I would apreciate any help.

Thanks.

error log:
uIP-2124.axf: Error: L6200E: Symbol file_cgi_files multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_cgi_stats multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_cgi_tcp multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_img_bg_png multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_about_html multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_control_html multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_404_html multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_files_footer_plain multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_files_header_html multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_index_html multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_stats_footer_plain multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_stats_header_html multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_tcp_footer_plain multiply defined (by fsdata.o and fs.o).
uIP-2124.axf: Error: L6200E: Symbol file_tcp_header_html multiply defined (by fsdata.o and fs.o).

Parents
  • Sorry for mistakes,

    I am going to check header files carefulle and try to resolve these problems, anyway I post them (headers files) just in case someone can help me:

    Thank you so much for your help.

    fs.h:

    #ifndef __FS_H__
    #define __FS_H__
    
    #include "uip.h"
    
    /**
     * An open file in the read-only file system.
     */
    struct fs_file {
      char *data;  /**< The actual file data. */
      int len;     /**< The length of the file data. */
    };
    
    /**
     * Open a file in the read-only file system.
     *
     * \param name The name of the file.
     *
     * \param file The file pointer, which must be allocated by caller and
     * will be filled in by the function.
     */
    int fs_open(const char *name, struct fs_file *file);
    
    #ifdef FS_STATISTICS
    #if FS_STATISTICS == 1
    u16_t fs_count(char *name);
    #endif /* FS_STATISTICS */
    #endif /* FS_STATISTICS */
    
    /**
     * Initialize the read-only file system.
     */
    void fs_init(void);
    
    #endif /* __FS_H__ */
    

    fsdata.h

    #ifndef __FSDATA_H__
    #define __FSDATA_H__
    
    
    #include "uipopt.h"
    struct fsdata_file { const struct fsdata_file *next; const char *name; const char *data; const int len; #ifdef FS_STATISTICS #if FS_STATISTICS == 1 u16_t count; #endif /* FS_STATISTICS */ #endif /* FS_STATISTICS */ };
    struct fsdata_file_noconst { struct fsdata_file *next; char *name; char *data; int len; #ifdef FS_STATISTICS #if FS_STATISTICS == 1 u16_t count; #endif /* FS_STATISTICS */ #endif /* FS_STATISTICS */ };
    #endif /* __FSDATA_H__ */

Reply
  • Sorry for mistakes,

    I am going to check header files carefulle and try to resolve these problems, anyway I post them (headers files) just in case someone can help me:

    Thank you so much for your help.

    fs.h:

    #ifndef __FS_H__
    #define __FS_H__
    
    #include "uip.h"
    
    /**
     * An open file in the read-only file system.
     */
    struct fs_file {
      char *data;  /**< The actual file data. */
      int len;     /**< The length of the file data. */
    };
    
    /**
     * Open a file in the read-only file system.
     *
     * \param name The name of the file.
     *
     * \param file The file pointer, which must be allocated by caller and
     * will be filled in by the function.
     */
    int fs_open(const char *name, struct fs_file *file);
    
    #ifdef FS_STATISTICS
    #if FS_STATISTICS == 1
    u16_t fs_count(char *name);
    #endif /* FS_STATISTICS */
    #endif /* FS_STATISTICS */
    
    /**
     * Initialize the read-only file system.
     */
    void fs_init(void);
    
    #endif /* __FS_H__ */
    

    fsdata.h

    #ifndef __FSDATA_H__
    #define __FSDATA_H__
    
    
    #include "uipopt.h"
    struct fsdata_file { const struct fsdata_file *next; const char *name; const char *data; const int len; #ifdef FS_STATISTICS #if FS_STATISTICS == 1 u16_t count; #endif /* FS_STATISTICS */ #endif /* FS_STATISTICS */ };
    struct fsdata_file_noconst { struct fsdata_file *next; char *name; char *data; int len; #ifdef FS_STATISTICS #if FS_STATISTICS == 1 u16_t count; #endif /* FS_STATISTICS */ #endif /* FS_STATISTICS */ };
    #endif /* __FSDATA_H__ */

Children