Installation

Installer Aspose.Email FOSS for C++

Aspose.Email FOSS for C++ har ingen eksterne afhængigheder. Det kræver en C++17-kompilator og CMake 3.14 eller senere.

Trin 1: Klon repository

git clone https://github.com/aspose-email-foss/Aspose.Email-FOSS-for-Cpp.git

Trin 2: Tilføj som CMake‑undermappe

I dit projekt CMakeLists.txt:

cmake_minimum_required(VERSION 3.14)
project(my_project)

add_subdirectory(Aspose.Email-FOSS-for-Cpp)

add_executable(my_app main.cpp)
target_link_libraries(my_app PRIVATE aspose_email_foss)

Trin 3: Inkluder overskrifter

#include "aspose/email/foss/msg/mapi_message.hpp"
#include "aspose/email/foss/cfb/cfb_reader.hpp"

Alle offentlige header-filer findes under include/aspose/email/foss/. De to hovedundersystemer er:

UndersystemHeader-mappeVigtige klasser
CFBcfb/cfb_reader, cfb_writer, cfb_document, cfb_node
MSGmsg/mapi_message, msg_reader, msg_writer, msg_document

Trin 4: Byg og verificer

cmake -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build

Bekræft med et minimalt program:

#include <iostream>
#include "aspose/email/foss/msg/mapi_message.hpp"

int main()
{
    auto message = aspose::email::foss::msg::mapi_message::create("Test", "Hello");
    std::cout << message.subject() << '\n';
    // Output: Test
}

Understøttede platforme

PlatformKompilatorMinimumsversion
LinuxGCC9+
LinuxClang10+
macOSApple Clang12+
WindowsMSVC2019 (16.0+)

Biblioteket bygges identisk på alle platforme uden platformsspecifik kode eller native afhængigheder.

 Dansk