Commit Graph

236 Commits

Author SHA1 Message Date
Petr Zemek
49932476a4 Remove references to our original (internal) issue tracker.
They are no longer relevant as we have migrated the code to GitHub.
2018-02-08 13:29:37 +01:00
Petr Zemek
1db0cb6379 Fix grammar in .appveyor.yml and .travis.yml files. 2018-02-06 06:32:48 +01:00
Petr Zemek
4b66a11dba doxygen: Remove useless trailing whitespace from doxygen.cfg.in. 2018-02-04 19:24:01 +01:00
Petr Zemek
9a65ac6992 doxygen: Rename doxygen.in to doxygen.cfg.in.
The new name is better at reflecting the fact that this is the input for the
creating of a configuration file.
2018-02-04 18:07:52 +01:00
Petr Zemek
637632d26c cmake: Remove the openssl-target-not-yet-exists guard.
It is no longer needed (we no longer use submodules in our repositories).
2018-02-04 10:04:03 +01:00
Petr Zemek
b0dfa26cfb cmake: Unify 'if (' vs 'if('. 2018-02-04 09:12:52 +01:00
Petr Zemek
5545a49c38 Add a new CHANGELOG entry (#76). 2018-02-04 08:59:07 +01:00
Petr Zemek
f4e7a6315f Add more C++-standard-related CMake options to CMakeLists.txt (#76).
set(CMAKE_CXX_STANDARD_REQUIRED ON)
This makes C++14 a requirement and prevents a "decay" to C++98 when the
compiler does not support C++14. RetDec and related tools require C++14 to
build, so the sooner the build fails the better.

set(CMAKE_CXX_EXTENSIONS OFF)
This disables the use of compiler-specific extensions. For example, by default,
CMake passes -std=gnu++14 to GCC on Linux. We want to build with -std=c++14 to
prevent use of non-portable compiler extensions, which is what the disabling of
this option does.
2018-02-04 08:53:33 +01:00
Peter Matula
6489bd2d36 scripts/retdec-decompiler.sh: improve error messages. 2018-01-31 12:22:47 +01:00
Petr Zemek
30e396e582 Point the AppVeyor badge link to master build in README.
Since we are showing status of the master branch, we want the link to point to
the master branch.
2018-01-31 11:50:55 +01:00
Peter Matula
40cedad996 llvmir-emul: fix warning about unused variable in Release build. 2018-01-29 14:26:44 +01:00
Peter Matula
4b0b7b7922 travis-ci: fix bash script execution on linux. 2018-01-26 18:20:50 +01:00
Peter Matula
b7544107e2 appveyor-ci: remove "cmd: rm -rf build" command.
This command is suddenly failing, even though it was ok in testing
branche. I have no idea why so the hell with it.
2018-01-26 17:20:50 +01:00
Peter Matula
62527970f3 add travis CI and appveyor CI configs 2018-01-26 16:09:07 +01:00
Peter Matula
9c0ba3a1a1 scripts/retdec-tests-runner.sh: add verbose parameter. 2018-01-26 11:41:01 +01:00
Petr Zemek
b966679f50 Add two entries into CHANGELOG (build speedup + system OpenSSL). 2018-01-26 11:39:01 +01:00
Petr Zemek
db29db551e cmake: Remove unused variable DEPS_TESTS. 2018-01-26 10:55:40 +01:00
Peter Matula
bd92e8f2b4 fix compilation -- some files got messed up at merge. 2018-01-26 10:53:57 +01:00
Petr Zemek
55f5c77b60 ar-extractor: Replace old C cast with a C++ cast.
Fixes the following compilation warning:

    src/ar-extractor/archive_wrapper.cpp:231:49: warning: use of old-style cast [-Wold-style-cast]
2018-01-26 10:45:28 +01:00
Petr Zemek
e23c607046 cmake: Set up compilation warnings.
Linux/macOS: Enable warnings.

MSVC: For the moment, suppress all warnings when building with MSVC on Windows
because there are too many warnings that clutter the build output (#106). We
should definitely investigate the warnings, fix them, and then enable their
emission (e.g. with replacing /W0 with /W3).
2018-01-26 10:45:18 +01:00
Peter Matula
3723cc295b deps/llvm: update referene to latest commmit from master. 2018-01-26 10:32:17 +01:00
Peter Matula
23ba7b944f Merge branch 'faster-build' 2018-01-26 10:27:01 +01:00
Petr Zemek
d23f2c6955 scripts: Unify formatting in retdec-decompiler.sh. 2018-01-25 17:29:54 +01:00
Marek Milkovič
fd7fa3f4d3 Merge branch 'yangfl-filesystem-path-enh' 2018-01-25 07:31:23 +01:00
Marek Milkovič
b610e38433 Added memory freeing into SCOPE_EXIT in case anything throws an
exception
2018-01-25 07:30:18 +01:00
Marek Milkovič
1b193f1d81 Merge branch 'upstream' of git://github.com/yangfl/retdec into yangfl-filesystem-path-enh 2018-01-25 06:58:25 +01:00
Petr Zemek
dcfc5ca224 unpacker: Fix a typo in the description of DynamicBuffer::operator=(). 2018-01-24 20:11:43 +01:00
Petr Zemek
b3f8f824d2 utils: Make tests for time-related functions timezone-agnostic (#90).
In timestampToDate(), std::localtime() is called to convert the timestamp into
a date and time. Since std::localtime() is timezone-aware, we have to force a
specific timezone (UTC) in tests to make them timezone-agnostic. After each
test is run, we set the timezone back to its original value.
2018-01-24 09:01:22 +01:00
Petr Zemek
7032c4231d utils: Rename OS_LINUX to OS_UNIX.
At the moment, we (unofficially) support also macOS, so differentiate only
between Windows and UNIX by defining the following two symbolic constants:
* OS_WINDOWS
* OS_UNIX
2018-01-24 08:09:57 +01:00
Petr Zemek
0067f9f70d utils: Unify formatting in the time module.
Inside a single file, we should use definitely use the same format.
2018-01-24 07:56:39 +01:00
Petr Zemek
f9f58bc174 Update GoogleTest to its latest version (current master).
The new version can be built faster:

    Original version:

        real    0m11.028s
        user    0m10.241s
        sys     0m0.782s

    Latest version:

        real    0m5.178s
        user    0m4.753s
        sys     0m0.425s

As a related change, this commit adds missing dependencies between the
gtest_main, gmock, and gmock_main libraries. In the original version,
libgmock.a contained libgtest.a and libgmock_main.a contained libgmock.a. Now,
libgmock.a is without libgtest.a and libgmock_main.a is without libgmock.a.
Thus, if one wants to link gmock_main, he or she has to also link gmock and
gtest. This has been reflected in the dependencies.
2018-01-23 13:41:29 +01:00
Peter Matula
5c2c13429a deps/openssl: better log msgs. 2018-01-23 11:24:25 +01:00
yangfl
a22178d214 Let realpath allocate a buffer itself 2018-01-23 18:04:38 +08:00
Petr Zemek
8f1d7f7e38 Mention #100 in CHANGELOG. 2018-01-23 08:20:33 +01:00
Petr Zemek
b0a9829e8c Update the used version of avast-tl/libdwarf.
The updated version contains commit 85465d5e235cc2d2f90d04016d6aca1a452d0e73,
which fixes the setting of RPATH during installation (#100).
2018-01-23 08:17:09 +01:00
Peter Matula
315adc431f deps/openssl: simplify openssl-crypto target from find_package() 2018-01-22 17:50:14 +01:00
Peter Matula
1cfc9c4fbb deps/openssl: use system OpenSLL if it exists. 2018-01-22 17:31:42 +01:00
Peter Matula
296ebfe5fd Merge branch 'master' into faster-build
# Conflicts:
#	deps/capstone/CMakeLists.txt
#	deps/elfio/CMakeLists.txt
#	deps/llvm/CMakeLists.txt
2018-01-22 16:32:05 +01:00
Peter Matula
a991b17a7f deps: propagate C/C++ compilers to all deps. 2018-01-22 16:20:10 +01:00
Petr Zemek
8bf8507f05 Merge branch 'fix-path-detections' (#21). 2018-01-21 11:39:29 +01:00
Petr Zemek
90767ab6f8 Add support for Cygwin paths into scripts (#21).
Based on #21:

    The scripts will also fail on Cygwin, due to Cygwin's virtual paths (c:
    becomes /cygdrive/c/, and so on), which are not transformed by readlink.
    Instead, one needs to use cygpath, to get the real windows path. So I've
    added get_realpath to retdec-utils.sh, to check if the scripts are running
    on Cygwin, and if they do, to use cygpath -ma (-a = absolute path, and -m =
    mixed, i.e., forward slashes rather than backward slashes). Otherwise it
    just uses readlink.
2018-01-21 10:56:59 +01:00
Petr Zemek
d0086e63c6 Fix the detection of SCRIPT_DIR in the beginning of scripts (#21).
Based on #21:

    Right now, the scripts used by retdec (e.g. retdec-decompiler.sh) will fail
    if they're symlinked, i.e., retdec-decompiler.sh symlinked to
    ~/bin/retdec-decompiler, because both ${BASH_SOURCE} and $0 will always
    point at the symlinked path, rather than the original, so $SCRIPT_DIR would
    become invalid.

    This is easy enough to fix, by doing dirname "$(readlink -e "$0")", rather
    than the pretty ancient style of cding to dirname "$0" (pretty sure this
    has been out of date since the inception of Linux itself ...).
2018-01-21 10:52:32 +01:00
Petr Zemek
d5d173783b Rename SCRIPTPATH to SCRIPT_DIR in scripts.
The new name is more appropriate (it is a directory) and consistent with the
naming of other variables storing directory paths.
2018-01-21 10:48:18 +01:00
Peter Matula
f036d11a6e use URL instead of SOURCE_DIR 2018-01-19 20:06:08 +01:00
Peter Matula
179e785bcf bin2llvmir: remove codegen passes initialization. 2018-01-19 19:36:16 +01:00
Peter Matula
aec8aac4a1 deps/llvm: remove LLVMAsmPrinter & LLVMSelectionDAG from LLVM_LIB_LIST 2018-01-19 15:44:08 +01:00
Peter Matula
bd54527cb0 deps/llvm: remove execution engine related libs from LLVM_LIB_LIST
The following libs are removed:
	LLVMInterpreter
	LLVMMCJIT
	LLVMOrcJIT
	LLVMExecutionEngine
	LLVMRuntimeDyld
They were used in llvm_emul.
2018-01-19 15:41:06 +01:00
Peter Matula
ccca6a24e6 llvmir_emul: remove unnecessary LLVM includes. 2018-01-19 15:39:27 +01:00
Peter Matula
134f5e66a8 bin2llvmir: remove initializeInstrumentation() & LLVMInstrumentation 2018-01-19 15:21:54 +01:00
Peter Matula
689872a78f bin2llvmir: remove initializeObjCARCOpts() & associated LLVMObjCARCOpts 2018-01-19 15:20:42 +01:00