[DO-972][DO-980] add freetype and pkgconf recipes (!6)
Co-authored-by: aleksandr.vodyanov <aleksandr.vodyanov@avroid.tech> Reviewed-on: https://git.avroid.tech/Conan/conan_build/pulls/6
This commit is contained in:
6
recipes/pkgconf/all/test_package/src/CMakeLists.txt
Normal file
6
recipes/pkgconf/all/test_package/src/CMakeLists.txt
Normal file
@@ -0,0 +1,6 @@
|
||||
cmake_minimum_required(VERSION 3.15)
|
||||
project(test_package LANGUAGES C)
|
||||
|
||||
find_package(pkgconf REQUIRED)
|
||||
add_executable(${PROJECT_NAME} test_package.c)
|
||||
target_link_libraries(${PROJECT_NAME} PRIVATE pkgconf::pkgconf)
|
||||
6
recipes/pkgconf/all/test_package/src/libexample1.pc
Normal file
6
recipes/pkgconf/all/test_package/src/libexample1.pc
Normal file
@@ -0,0 +1,6 @@
|
||||
Name: libexample1
|
||||
Description: This is a description of libexample1.
|
||||
Requires:
|
||||
Version: 0.42
|
||||
Libs: -L/usr/lib -lexample1
|
||||
Cflags: -I/usr/include/libexample1 -I/usr/include -DEXAMPLE1_STATIC
|
||||
24
recipes/pkgconf/all/test_package/src/test_package.c
Normal file
24
recipes/pkgconf/all/test_package/src/test_package.c
Normal file
@@ -0,0 +1,24 @@
|
||||
#include "libpkgconf/libpkgconf.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
bool error_callback(const char *msg, const pkgconf_client_t *client, const void *data) {
|
||||
printf("error callback: %s\n", msg);
|
||||
fflush(stdout);
|
||||
return 1; // 1/true means message handled
|
||||
}
|
||||
|
||||
int main() {
|
||||
pkgconf_client_t client;
|
||||
memset(&client, 0, sizeof(client));
|
||||
|
||||
pkgconf_client_init(&client, error_callback, NULL, pkgconf_cross_personality_default());
|
||||
|
||||
pkgconf_error(&client, "%s:%d %s: %s", __FILE__, __LINE__, __FUNCTION__, "test error");
|
||||
|
||||
pkgconf_client_deinit(&client);
|
||||
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user