Skip to content

Commit

Permalink
Merge pull request #94 from andreasBihlmaier/fix-aarch64
Browse files Browse the repository at this point in the history
fix compilation on aarch64 (e.g. Ubuntu 18.04.4 on Raspberry Pi 4)
  • Loading branch information
rohbotics authored Jul 2, 2020
2 parents c5a81d6 + 0df5256 commit 99ccecf
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ project(raspicam_node)


set(CMAKE_CXX_STANDARD 14) # use C++14
set(CMAKE_EXE_LINKER_FLAGS "-Wl,--no-as-needed") # https://github.com/raspberrypi/userland/issues/178

## Find catkin macros and libraries
## if COMPONENTS list like find_package(catkin REQUIRED COMPONENTS xyz)
Expand Down
4 changes: 2 additions & 2 deletions src/RaspiCamControl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

#ifdef __arm__
#if defined(__arm__) || defined(__aarch64__)

#include <memory.h>
#include <stdio.h>
Expand Down Expand Up @@ -919,4 +919,4 @@ void raspicamcontrol_check_configuration(int min_gpu_mem) {
vcos_log_error("Failed to run camera app. Please check for firmware updates\n");
}

#endif // __arm__
#endif // __arm__ || __aarch64__
4 changes: 2 additions & 2 deletions src/raspicam_node.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ int main(int argc, char** argv) {

#endif // __x86_64__

#ifdef __arm__
#if defined(__arm__) || defined(__aarch64__)

// We use some GNU extensions (basename)
#include <memory.h>
Expand Down Expand Up @@ -1380,4 +1380,4 @@ int main(int argc, char** argv) {
ros::shutdown();
}

#endif // __arm__
#endif // __arm__ || __aarch64__

0 comments on commit 99ccecf

Please sign in to comment.