poac-dev / poac Goto Github PK
View Code? Open in Web Editor NEWA package manager and build system for C++
Home Page: https://poac.dev
License: Apache License 2.0
A package manager and build system for C++
Home Page: https://poac.dev
License: Apache License 2.0
poac install boost/config
等を実行して,poac.ymlが書き換えられるとコメントが消えてしまう
I am using C ++ IDE CLion and must use CMake.
I wonder if you can use poac in CMake. If so, how should I use it?
(サポート予定があるかどうかわからないですが) cygwin 環境でのビルドができない状態です。
ログ : https://gist.github.com/fd00/f589f0c42f3677117d9fc3e8f43474e2
resolve
以外のエラーは -D_GNU_SOURCE
で解決します。resolve
は引数 port
の型がきちんと解釈できていないように見えるのですが cygwin gcc 特有のものかはわからないです...。環境
$ /usr/bin/c++ -v
Using built-in specs.
COLLECT_GCC=/usr/bin/c++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-pc-cygwin/7.4.0/lto-wrapper.exe
Target: x86_64-pc-cygwin
Configured with: /cygdrive/i/szsz/tmpp/gcc/gcc-7.4.0-1.x86_64/src/gcc-7.4.0/configure --srcdir=/cygdrive/i/szsz/tmpp/gcc/gcc-7.4.0-1.x86_64/src/gcc-7.4.0 --prefix=/usr --exec-prefix=/usr --localstatedir=/var --sysconfdir=/etc --docdir=/usr/share/doc/gcc --htmldir=/usr/share/doc/gcc/html -C --build=x86_64-pc-cygwin --host=x86_64-pc-cygwin --target=x86_64-pc-cygwin --without-libiconv-prefix --without-libintl-prefix --libexecdir=/usr/lib --enable-shared --enable-shared-libgcc --enable-static --enable-version-specific-runtime-libs --enable-bootstrap --enable-__cxa_atexit --with-dwarf2 --with-tune=generic --enable-languages=ada,c,c++,fortran,lto,objc,obj-c++ --enable-graphite --enable-threads=posix --enable-libatomic --enable-libcilkrts --enable-libgomp --enable-libitm --enable-libquadmath --enable-libquadmath-support --disable-libssp --enable-libada --disable-symvers --with-gnu-ld --with-gnu-as --with-cloog-include=/usr/include/cloog-isl --without-libiconv-prefix --without-libintl-prefix --with-system-zlib --enable-linker-build-id --with-default-libstdcxx-abi=gcc4-compatible --enable-libstdcxx-filesystem-ts
Thread model: posix
gcc version 7.4.0 (GCC)
helpとversionをサブコマンドとしても使用できるようにする.
optionとしても使用可能に.
poac help
poac --help
poac -h
パッケージリポジトリに poac
の依存パッケージが存在しないため, poac
に対して poac install
を行うとコケる.
boost/property_tree
boost/filesystem
boost/range
boost/algorithm
boost/foreach
boost/dynamic_bitset
boost/beast
cpp-shell-cmd
--example NAME
Perhaps it will work well with the following:
brew unlink boost
brew install --ignore-dependencies boost
Or, remove before_cache
?
src
|- include/
|- main.cpp
|_ CMakeLists.txt
yaml-dev
システムパッケージで導入される YAML
のヘッダーは /usr/include/yaml.h
のように導入される。
poac
ソースコードでは複数箇所で YAML
のヘッダーの所在に独自のプリフィックス(サブ・ディレクトリー) yaml-cpp/
を想定した #include
が定義されているため、この部分のソースコードの改変が必要。#include
を書き、必要に応じて #ifdef
等で yaml-cpp/
を与えるのがよいのではないか、と思う。(私は OSX 開発環境に詳しくないので __APPLE__
とすべきか、あるいは特定パッケージマネージャーを判定する方法があるか、または cmake
レベルでヘッダーの所在を探索して変数へ入れるべきかまではわかりません。)せっかくなので遊んでみよう!と思ったのですが、イケメンC++erだけでなく、一般C++erも手軽にビルドできないとちょっと厳しいかなーと思います。あるいはバイナリーパッケージを提供してしまうというのも手だけど…。
template<typename Conf>
void enable_gnu(Conf& conf) {
conf.version_prefix = "-std=gnu++";
}
icp
Write to buildsystem.hpp
bool _cmake_build(
const std::string& pkgname,
const std::map<std::string, std::string>& cmake_envs )
{
namespace fs = boost::filesystem;
namespace except = core::exception;
const fs::path filepath = io::file::path::poac_cache_dir / pkgname;
util::command cmd("cd " + filepath.string());
cmd &= "mkdir build";
cmd &= "cd build";
util::command cmake_cmd("cmake ..");
for (const auto& [key, val] : cmake_envs)
cmake_cmd.env(key, val);
cmd &= cmake_cmd.stderr_to_stdout();
cmd &= util::command("make -j4").stderr_to_stdout();
cmd &= util::command("make install").env("DESTDIR", "./").stderr_to_stdout();
if (auto result = cmd.exec()) {
const std::string filepath_tmp = filepath.string() + "_tmp";
fs::rename(filepath, filepath_tmp);
fs::create_directories(filepath);
const fs::path build_after_dir(fs::path(filepath_tmp) / "build" / "usr" / "local");
// Write to cache.yml and recurcive copy
for (const auto& s : std::vector<std::string>({ "bin", "include", "lib" }))
if (io::file::path::validate_dir(build_after_dir / s))
io::file::path::recursive_copy(build_after_dir / s, fs::path(filepath) / s);
fs::remove_all(filepath_tmp);
return EXIT_SUCCESS;
}
else {
/* error */
// datetime-error.log
return EXIT_FAILURE;
}
}
https://doc.rust-lang.org/cargo/reference/build-scripts.html
Necessary when using protobuf
etc.
It depends too much on main.cpp
For speeding up...
ドキュメントでは boost-1.48 以降でビルド可能な事になっている。
しかし、実際にビルドを試みると Boost.Beast ライブラリーを使用しているため、 boost-1.66 以降でなければビルドできない。
cmake
引数等で設定可能にするCurrently, README says that the result of AppVeyor building is build status on WSL.
However, the result is build status using MSVC, not on WSL.
The description should be changed.
--no-cache
Only when using poac
./poac.ymlのcpp_versionに書かれたバージョンより古いバージョンのパッケージをinstallする時に,警告を表示する.
GET /api/packages/:name/:version/cpp_version
poac::subcmd::_install::_main
等からinference〜main.cppまで,intを返す
現状,poac.ymlのcpp_versionをそのまま渡している
cpp_versionの検証(98, 03, 11, 14, 17, 20)を行うのと,1z等に変換する必要がある
#55
--release
e.g. man, docs, completion, ...
Currently, users manually download windows binary from GitHub releases, because sh.poac.pm can't install it.
However, I do not know how to install the latest libstd.
Therefore, I committed 3bf0b83 as a temporary measure.
Docker image is placed here and here.
It is probably because the c++17 features are not installed.
https://circleci.com/gh/poacpm/poac/185?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link
All subcommand and options
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.