From 8e2dbd441c6511f1ce15f41dff267c6bfdaefafe Mon Sep 17 00:00:00 2001 From: Claudius Holeksa Date: Sat, 29 Apr 2023 18:06:59 +0200 Subject: Fixed async build and added result-dev to ignore --- .gitignore | 1 + forstio/async/SConstruct | 24 +++++++++--------------- forstio/async/async.cpp | 4 ++-- forstio/async/async.h | 4 ++-- forstio/async/async.tmpl.h | 4 ++-- 5 files changed, 16 insertions(+), 21 deletions(-) diff --git a/.gitignore b/.gitignore index 8e3ab66..624e904 100644 --- a/.gitignore +++ b/.gitignore @@ -9,6 +9,7 @@ # nix result +result-dev # regular target which is not really used build diff --git a/forstio/async/SConstruct b/forstio/async/SConstruct index 2d5050f..0d7b7c6 100644 --- a/forstio/async/SConstruct +++ b/forstio/async/SConstruct @@ -35,38 +35,32 @@ def isAbsolutePath(key, dirname, env): env_vars = Variables( args=ARGUMENTS -); +) env_vars.Add('prefix', help='Installation target location of build results and headers', default='/usr/local/', validator=isAbsolutePath -); +) env=Environment(ENV=os.environ, variables=env_vars, CPPPATH=[], CPPDEFINES=['SAW_UNIX'], CXXFLAGS=['-std=c++20','-g','-Wall','-Wextra'], - LIBS=[]); -env.__class__.add_source_files = add_kel_source_files; + LIBS=['forstio-core']) +env.__class__.add_source_files = add_kel_source_files env.Tool('compilation_db'); env.cdb = env.CompilationDatabase('compile_commands.json'); env.objects = []; env.sources = []; env.headers = []; +env.targets = []; -Export('env'); -SConscript('src/forstio/async/SConscript'); - -# Tests -# SConscript('tests/SConscript') -# env.Alias('test', env.test_program) +Export('env') +SConscript('SConscript') env.Alias('cdb', env.cdb); -env.Alias('all', ['library']);# , 'test']) +env.Alias('all', [env.targets]); env.Default('all'); -env.Install('$prefix/lib/', [env.library_shared, env.library_static]); -env.Install('$prefix/include/forstio/async/', [env.headers]); - -env.Alias('install', '$prefix'); +env.Alias('install', '$prefix') diff --git a/forstio/async/async.cpp b/forstio/async/async.cpp index 7d177f5..ca85b30 100644 --- a/forstio/async/async.cpp +++ b/forstio/async/async.cpp @@ -1,6 +1,6 @@ #include "async.h" -#include -#include +#include +#include #include #include diff --git a/forstio/async/async.h b/forstio/async/async.h index 4e4f230..82eb2c1 100644 --- a/forstio/async/async.h +++ b/forstio/async/async.h @@ -1,7 +1,7 @@ #pragma once -#include -#include +#include +#include #include #include diff --git a/forstio/async/async.tmpl.h b/forstio/async/async.tmpl.h index e4dc54a..77a24da 100644 --- a/forstio/async/async.tmpl.h +++ b/forstio/async/async.tmpl.h @@ -1,7 +1,7 @@ #pragma once -#include -#include +#include +#include #include // Template inlining -- cgit v1.2.3