[Pkg-varnish-devel] Bug#745902: libvarnishapi-dev: 'struct VSC_C_main' not defined

Sebastian Harl tokkee at debian.org
Sat Apr 26 13:24:08 UTC 2014


Package: libvarnishapi-dev
Version: 4.0.0-1
Severity: serious

Hi,

/usr/include/varnish/vapi/vsc.h includes the following function:

  struct VSC_C_main *VSC_Main(const struct VSM_data *vd,
      struct VSM_fantom *fantom);

struct VSC_C_main is not defined in any of the headers shipped in
/usr/include/. Instead, it is defined in
/usr/share/varnish/include/common/common.h.

I'm not sure what the files in /usr/share/varnish/include/ are supposed
to be used for but they are fairly unusable. For example, common.h
includes /usr/share/varnish/include/vas.h which unconditionally defines
assert(), thus conflicting with /usr/include/assert.h. Also, the files
in /usr/share/ redefine various things which are also defined in headers
in /usr/include/, for example:

  In file included from /usr/share/varnish/include/common/common.h:42:0,
                   from varnish.c:35:
  /usr/include/varnish/vapi/vsc_int.h:34:6: error: nested redefinition of 'enum VSC_level_e'
   enum VSC_level_e {
        ^
  /usr/include/varnish/vapi/vsc_int.h:34:6: error: redeclaration of 'enum VSC_level_e'
  In file included from /usr/include/varnish/vapi/vsc.h:38:0,
                   from varnish.c:32:
  /usr/include/varnish/vapi/vsc_int.h:34:6: note: originally defined here
   enum VSC_level_e {
        ^

That's the point where I stopped trying to migrate code in collectd to
varnish 4.

I think it's fine to have the code in /usr/share/ conflict with
/usr/include/. After all, /usr/share/ seems to be used for Varnish
modules only. However, /usr/include/ needs to be self-containing.

Thanks,
Sebastian

-- 
Sebastian "tokkee" Harl +++ GnuPG-ID: 0x8501C7FC +++ http://tokkee.org/

Those who would give up Essential Liberty to purchase a little Temporary
Safety, deserve neither Liberty nor Safety.         -- Benjamin Franklin

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-varnish-devel/attachments/20140426/e698e4a6/attachment.sig>


More information about the Pkg-varnish-devel mailing list