This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux Desktop SDK 1.0.0.6 compilaition error

Hi,

I am using default configuration of Kubuntu 64bit 12.10 and installed Linux Desktop SDK 1.0.0.6 64bit. I got compilation error while executing make:

gcc -Werror -ggdb  -I . -I inc -I ../ -I shared -I ../sync -D _FILE_OFFSET_BITS=64  -c src/pciedrv.c -o obj/pciedrv.o
src/pciedrv.c: In function ‘pciedrv_map_dspaddr_to_inbound’:
src/pciedrv.c:2169:7: error: format ‘%X’ expects argument of type ‘unsigned int’, but argument 5 has type ‘size_t’ [-Werror=format]
cc1: all warnings being treated as errors
make[1]: *** [obj/pciedrv.o] Error 1
make[1]: Leaving directory `/opt/ti/desktop-linux-sdk_01_00_00_06/sdk/pciedrv'
make: *** [pciedrv] Error 2

The issue is not critical and I know how to overcome it but I hope it will be fixed in next releases.

Regards,

Andrey Lisnevich

  • Hello Andrey,

    This is a bug in the format for fprintf.

    Please replace the line 2168:2169 ( Note the addition of z)

        fprintf(stderr, "%s: ERROR:  pciedrv_bar_cfg: Size to be mapped to BAR is too large! (0x%X > 0x%X)\n",
          progname, size, driverinst.pcieendpoint[dsp_id].memregions[bar_num].size);
     with

        fprintf(stderr, "%s: ERROR:  pciedrv_bar_cfg: Size to be mapped to BAR is too large! (0x%X > 0x%zX)\n",
          progname, size, driverinst.pcieendpoint[dsp_id].memregions[bar_num].size);


     This will resolve the issue.

    with regards,

    sam