Browse Source

Moved the cmake building to build/

Smoolak 1 year ago
parent
commit
012da51d07
2 changed files with 6 additions and 5 deletions
  1. 1
    0
      README.md
  2. 5
    5
      build/CMakeLists.txt

+ 1
- 0
README.md View File

@@ -5,6 +5,7 @@ A library for reading and manipulating Parrot's drones pud and black box files.
5 5
 ## Install instructions
6 6
 
7 7
 ```bash
8
+cd build
8 9
 cmake .
9 10
 make
10 11
 sudo make install

CMakeLists.txt → build/CMakeLists.txt View File

@@ -18,17 +18,17 @@
18 18
 cmake_minimum_required(VERSION 3.9)
19 19
 project(readbop VERSION 1.0 DESCRIPTION "A library for reading and manipulating Parrot's drones pud and black box files")
20 20
 include(GNUInstallDirs)
21
-add_library(readbop SHARED src/readbop.c)
22
-set_target_properties(readbop PROPERTIES PUBLIC_HEADER include/readbop.h)
23
-target_include_directories(readbop PRIVATE include)
24
-target_include_directories(readbop PRIVATE src)
21
+add_library(readbop SHARED ../src/readbop.c)
22
+set_target_properties(readbop PROPERTIES PUBLIC_HEADER ../include/readbop.h)
23
+target_include_directories(readbop PRIVATE ../include)
24
+target_include_directories(readbop PRIVATE ../src)
25 25
 install(TARGETS readbop
26 26
     LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
27 27
     PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
28 28
 
29 29
 include(CheckIncludeFiles)
30 30
 check_include_files("fcntl.h;errno.h;sys/types.h;sys/stat.h;unistd.h" POSIX_READ_FILE)
31
-configure_file(src/readbop.c.in src/readbop.c @ONLY)
31
+configure_file(../src/readbop.c.in ../src/readbop.c @ONLY)
32 32
 
33 33
 if(CMAKE_C_COMPILER_ID STREQUAL "GNU" OR CMAKE_C_COMPILER_ID MATCHES "Clang" OR CMAKE_C_COMPILER_ID STREQUAL "Intel" OR CMAKE_C_COMPILER_ID STREQUAL "XL")
34 34
 	set(CMAKE_C_FLAGS "-Ofast ${CMAKE_C_FLAGS}")

Loading…
Cancel
Save