DEBUG_HASH and DEBUG_HASH2 are undeclared

When trying to build a package I receive an error that DEBUG_HASH and DEBUG_HASH2 are undeclared. What should I do?

Fix the code.

It would be easier if you said which project and package have the problem (in general, also for your other problem). We can’t help you to fix a code we don’t see.

Here it is: https://build.opensuse.org/package/show?package=virtualbox-ose&project=home%3AAnsus%3AKDE3

But the file which brings error seems to belong to kernel headers (/usr/src/linux-2.6.34.7-0.5/include/net/inet_connection_sock.h ). Is it a bug in kernel-devel?

You have to define those. If you look at VirtualBox’s trunk they use “DEBUG_HASH=2 DEBUG_HASH2=3”.
Basically, you set DEBUG_FLAGS in the spec file but that has no effect, put it somewhere where is has… patching src/VBox/Additions/linux/sharedfolders/Makefile.kmk to look like trunk is the obvious fix.

ps. IMHO it makes no sense to package a version so old of VirtualBox. You don’t like KDE4 and prefere KDE? OK… but you are also going to use outdated versions of any software that uses Qt4? VirtualBox is big, its Qt interface is just a minor part.

Thank you. seems this works, but now I have

/usr/lib64/gcc/x86_64-suse-linux/4.1.2/…/…/…/…/x86_64-suse-linux/bin/ld: final link failed: Nonrepresentable section on output

I have changed the function visibility to default from hidden and now I can pass this pooint. I don’t know if this is a good solution.