Go back to Richel Bilderbeek's homepage.
Go back to Richel Bilderbeek's C++ page.
This Boost.Filesystem example shows how to count the number of files in a folder with certain requirements. This program shows how I count the number of C++ webpages on this site!
Technical facts
Operating system(s) or programming environment(s)
IDE(s):
Project type:
C++ standard:
Compiler(s):
Libraries used:
Boost: version 1.49
Qt: version 4.8.4 (32 bit)
STL: GNU ISO C++ Library, version 4.7.3
QT += core
QT -= gui
CONFIG += console
CONFIG -= app_bundle
TEMPLATE = app
SOURCES += main.cpp
unix {
LIBS += -lboost_system -lboost_filesystem
}
win32 {
INCLUDEPATH += \
../../Libraries/boost_1_53_0
#Boost.System
HEADERS += \
../../Libraries/boost_1_53_0/libs/system/src/local_free_on_destruction.hpp
SOURCES += \
../../Libraries/boost_1_53_0/libs/system/src/error_code.cpp
#Boost.Filesystem
HEADERS += \
../../Libraries/boost_1_53_0/libs/filesystem/src/windows_file_codecvt.hpp
SOURCES += \
../../Libraries/boost_1_53_0/libs/filesystem/src/codecvt_error_category.cpp \
../../Libraries/boost_1_53_0/libs/filesystem/src/operations.cpp \
../../Libraries/boost_1_53_0/libs/filesystem/src/path.cpp \
../../Libraries/boost_1_53_0/libs/filesystem/src/path_traits.cpp \
../../Libraries/boost_1_53_0/libs/filesystem/src/portability.cpp \
../../Libraries/boost_1_53_0/libs/filesystem/src/unique_path.cpp \
../../Libraries/boost_1_53_0/libs/filesystem/src/utf8_codecvt_facet.cpp \
../../Libraries/boost_1_53_0/libs/filesystem/src/windows_file_codecvt.cpp
}
|
main.cpp
crosscompiletowindows.sh
#!/bin/sh
#From http://richelbilderbeek.nl/CppQtCrosscompileToWindowsExample15.htm
echo "Cross compiling to Windows"
echo "1/2: Creating Windows makefile"
i686-pc-mingw32-qmake CppFilesystemExample1.pro
echo "2/2: making makefile"
make
echo "Done"
|
Go back to Richel Bilderbeek's C++ page.
Go back to Richel Bilderbeek's homepage.

This page has been created by the tool CodeToHtml