Skip to content

Commit

Permalink
Fix compilation under gcc7.5 (#81)
Browse files Browse the repository at this point in the history
* Correct typo in individual license file name

* Fix compilation under GCC 7.5 for Ubuntu
  • Loading branch information
huguesdpdn-aerospace authored Nov 4, 2024
1 parent 9e44ac5 commit 2e3659c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 5 additions & 0 deletions OndselSolver/ASMTAssembly.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,9 @@
#include "ASMTRotationLimit.h"
#include "ASMTTranslationLimit.h"
#include "ExternalSystem.h"
#if __GNUC__ >= 8
#include <filesystem>
#endif

using namespace MbD;

Expand Down Expand Up @@ -359,8 +361,11 @@ void MbD::ASMTAssembly::runSinglePendulum()

std::shared_ptr<ASMTAssembly> MbD::ASMTAssembly::assemblyFromFile(const std::string& fileName)
{
// https://stackoverflow.com/a/45867491
#if __GNUC__ >= 8
std::filesystem::path currentPath = std::filesystem::current_path();
std::cout << "Current directory: " << currentPath << std::endl;
#endif

std::ifstream stream(fileName);
if (stream.fail()) {
Expand Down
1 change: 0 additions & 1 deletion OndselSolverMain/OndselSolver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
* @brief Program to assemble a piston crank system.
*********************************************************************/

#include <filesystem>
#include "../OndselSolver/CADSystem.h"
#include "../OndselSolver/CREATE.h"
#include "../OndselSolver/GESpMatParPvPrecise.h"
Expand Down

0 comments on commit 2e3659c

Please sign in to comment.