Browse Source

Update README

- Add build section
Alexey Edelev 6 years ago
parent
commit
d887ee1ee2
2 changed files with 16 additions and 3 deletions
  1. 4 1
      CMakeLists.txt
  2. 12 2
      README.md

+ 4 - 1
CMakeLists.txt

@@ -3,6 +3,9 @@ cmake_minimum_required(VERSION 2.8)
 project(qtprotobuf)
 
 find_package(Protobuf)
-message("Protobuf libraries"${Protobuf_LIBRARIES})
+
 add_executable(${PROJECT_NAME} "src/generator/main.cpp" "src/generator/generator.cpp")
 target_link_libraries(${PROJECT_NAME} ${Protobuf_LIBRARIES} "-lprotoc")
+
+install(TARGETS ${PROJECT_NAME}
+    RUNTIME DESTINATION bin)

+ 12 - 2
README.md

@@ -1,8 +1,18 @@
-# qtprotobug
+# qtprotobuf
 
 Protobuf plugin to generate Qt classes
 
 # Build
 
+```bash
+mkdir build
+cd build
+cmake ..
+make -j<N>
+```
+
 # Usage
-protoc --plugin=protoc-gen-qtprotobuf=<path/to/compiled>/qtprotobuf --qtprotobuf_out=<output_dir> <protofile>.proto
+
+```bash
+protoc --plugin=protoc-gen-qtprotobuf=<path/to/bin>/qtprotobuf --qtprotobuf_out=<output_dir> <protofile>.proto
+```