2018-11-21 20:29:44 +03:00
|
|
|
/* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */
|
2019-12-27 00:02:53 +03:00
|
|
|
#include <iostream>
|
2018-11-21 20:29:44 +03:00
|
|
|
#include "libbpf.h"
|
|
|
|
#include "bpf.h"
|
|
|
|
#include "btf.h"
|
2019-12-27 00:02:53 +03:00
|
|
|
#include "test_core_extern.skel.h"
|
2018-11-21 20:29:44 +03:00
|
|
|
|
|
|
|
/* do nothing, just make sure we can link successfully */
|
|
|
|
|
|
|
|
int main(int argc, char *argv[])
|
|
|
|
{
|
2019-12-27 00:02:53 +03:00
|
|
|
struct test_core_extern *skel;
|
|
|
|
|
2019-10-11 03:28:04 +03:00
|
|
|
/* libbpf.h */
|
|
|
|
libbpf_set_print(NULL);
|
2018-11-21 20:29:44 +03:00
|
|
|
|
2019-10-11 03:28:04 +03:00
|
|
|
/* bpf.h */
|
|
|
|
bpf_prog_get_fd_by_id(0);
|
2018-11-21 20:29:44 +03:00
|
|
|
|
2019-10-11 03:28:04 +03:00
|
|
|
/* btf.h */
|
|
|
|
btf__new(NULL, 0);
|
|
|
|
|
2019-12-27 00:02:53 +03:00
|
|
|
/* BPF skeleton */
|
|
|
|
skel = test_core_extern__open_and_load();
|
|
|
|
test_core_extern__destroy(skel);
|
|
|
|
|
|
|
|
std::cout << "DONE!" << std::endl;
|
|
|
|
|
2019-10-11 03:28:04 +03:00
|
|
|
return 0;
|
2018-11-21 20:29:44 +03:00
|
|
|
}
|