wsutil: get_datafile_dir: avoid hard-coded build directory
authorPeter Wu <peter@lekensteyn.nl>
Tue, 2 Oct 2018 17:00:01 +0000 (19:00 +0200)
committerAnders Broman <a.broman58@gmail.com>
Wed, 3 Oct 2018 03:49:16 +0000 (03:49 +0000)
commit107205c2becb5a16b214cdbc471833fdfee077ab
tree1f08520cda0277e665db3c21ad1eca483f74928f
parent105f2d68d81416e322152f0edc62ec1434a9d604
wsutil: get_datafile_dir: avoid hard-coded build directory

With autotools, it was possible that the binary was located in a .libs
directory, but with CMake the executables directory and data directory
are the same (except macOS with app bundles). Use this property to get
rid of the hard-coded build directory. Helps with reproducible builds.

Bug: 15163
Change-Id: I5b8807a03783a9919fba7b0cc83f5c162caa8052
Reviewed-on: https://code.wireshark.org/review/29984
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
wsutil/CMakeLists.txt
wsutil/filesystem.c