Skip to content

Instantly share code, notes, and snippets.

@danmcd
Created September 17, 2018 17:31
Show Gist options
  • Save danmcd/ceb29e184f57c83c2dd083d16b8aec8d to your computer and use it in GitHub Desktop.
Save danmcd/ceb29e184f57c83c2dd083d16b8aec8d to your computer and use it in GitHub Desktop.
smartos-build(~)[0]% cat test.c
#include "/home/danmcd/nat-reform/projects/illumos/usr/src/uts/common/inet/vxlnat.h"
main()
{
vxn_msg_t vxnm;
vxnm.vxnm_type = 1;
printf("Hello, type = %d\n", vxnm.vxnm_type);
}
smartos-build(~)[0]% gcc -g -m64 -o t64 test.c
test.c: In function 'main':
test.c:8:2: warning: incompatible implicit declaration of built-in function 'printf' [enabled by default]
smartos-build(~)[0]% /opt/onbld/bin/i386/ctfmerge-altexec -o t64 t64
smartos-build(~)[0]% mdb t64
> ::print -at vxn_msg_t
mdb: failed to look up type vxn_msg_t: unknown object file name
>
smartos-build(~)[0]%
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment