mirror of
https://github.com/CHN-beta/nixos.git
synced 2026-01-12 01:29:24 +08:00
packages.mirism: drop
This commit is contained in:
@@ -34,12 +34,6 @@
|
||||
packages = [ pkgs.clang-tools_18 ];
|
||||
CMAKE_EXPORT_COMPILE_COMMANDS = "1";
|
||||
};
|
||||
mirism = pkgs.mkShell.override { stdenv = pkgs.clang18Stdenv; }
|
||||
{
|
||||
inputsFrom = [ pkgs.localPackages.mirism ];
|
||||
packages = [ pkgs.clang-tools_18 ];
|
||||
CMAKE_EXPORT_COMPILE_COMMANDS = "1";
|
||||
};
|
||||
info = pkgs.mkShell.override { stdenv = pkgs.clang18Stdenv; }
|
||||
{
|
||||
inputsFrom = [ pkgs.localPackages.info ];
|
||||
|
||||
@@ -96,7 +96,6 @@ inputs: rec
|
||||
chn-bsub = inputs.pkgs.callPackage ./chn-bsub { inherit biu; };
|
||||
py4vasp = inputs.pkgs.python3Packages.callPackage ./py4vasp.nix { src = inputs.topInputs.py4vasp; };
|
||||
pocketfft = inputs.pkgs.callPackage ./pocketfft.nix { src = inputs.topInputs.pocketfft; };
|
||||
mirism = inputs.pkgs.callPackage ./mirism { inherit biu; stdenv = inputs.pkgs.clang18Stdenv; };
|
||||
vaspberry = inputs.pkgs.callPackage ./vaspberry.nix { src = inputs.topInputs.vaspberry; };
|
||||
nvhpcPackages = inputs.pkgs.lib.makeScope inputs.pkgs.newScope (final:
|
||||
{
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
use flake .#mirism
|
||||
@@ -1,23 +0,0 @@
|
||||
cmake_minimum_required(VERSION 3.14)
|
||||
project(mirism VERSION 0.0.0 LANGUAGES CXX)
|
||||
enable_testing()
|
||||
include(GNUInstallDirs)
|
||||
|
||||
if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
|
||||
message("Setting build type to 'Release' as none was specified.")
|
||||
set(CMAKE_BUILD_TYPE Release CACHE STRING "Choose the type of build." FORCE)
|
||||
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" "MinSizeRel" "RelWithDebInfo")
|
||||
endif()
|
||||
|
||||
find_package(biu REQUIRED)
|
||||
find_package(httplib REQUIRED)
|
||||
|
||||
add_executable(mirism src/main.cpp)
|
||||
target_compile_features(mirism PUBLIC cxx_std_23)
|
||||
target_link_libraries(mirism PRIVATE biu::biu httplib::httplib)
|
||||
|
||||
install(TARGETS mirism RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
|
||||
get_property(ImportedTargets DIRECTORY "${CMAKE_SOURCE_DIR}" PROPERTY IMPORTED_TARGETS)
|
||||
message("Imported targets: ${ImportedTargets}")
|
||||
message("List of compile features: ${CMAKE_CXX_COMPILE_FEATURES}")
|
||||
@@ -1,7 +0,0 @@
|
||||
{ stdenv, cmake, pkg-config, biu, httplib }: stdenv.mkDerivation
|
||||
{
|
||||
name = "mirism";
|
||||
src = ./.;
|
||||
buildInputs = [ biu httplib ];
|
||||
nativeBuildInputs = [ cmake pkg-config ];
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
# include <biu.hpp>
|
||||
# include <httplib.h>
|
||||
|
||||
int main()
|
||||
{
|
||||
using namespace biu::literals;
|
||||
|
||||
httplib::SSLServer srv("/var/lib/acme/debug.mirism.one/fullchain.pem",
|
||||
"/var/lib/acme/debug.mirism.one/key.pem");
|
||||
srv.Get("/", [](const httplib::Request& req, httplib::Response& res) {
|
||||
std::cout << "{}"_f(req.headers) << std::endl;
|
||||
httplib::Client cli("https://github.com");
|
||||
auto upstream_res = cli.Get("/");
|
||||
res.headers = upstream_res->headers;
|
||||
res.body = upstream_res->body;
|
||||
res.status = upstream_res->status;
|
||||
std::cout << "{}"_f(upstream_res->headers) << std::endl;
|
||||
std::cout << "{}"_f(upstream_res->body) << std::endl;
|
||||
});
|
||||
srv.listen("127.0.0.1", 15641);
|
||||
}
|
||||
Reference in New Issue
Block a user