Skip to content

Commit

Permalink
use submodules
Browse files Browse the repository at this point in the history
  • Loading branch information
jared2020 committed Jan 25, 2021
1 parent bc9c174 commit 28f15f3
Show file tree
Hide file tree
Showing 14 changed files with 42 additions and 6 deletions.
1 change: 1 addition & 0 deletions .github/workflows/android-qt5_15_2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ jobs:
- uses: actions/checkout@v1
with:
fetch-depth: 1
submodules: 'true'
- name: build android
run: |
export ANDROID_SDK_ROOT=$ANDROID_HOME
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ jobs:
- uses: actions/checkout@v1
with:
fetch-depth: 1
submodules: 'true'
- name: build android
run: |
export ANDROID_SDK_ROOT=$ANDROID_HOME
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ jobs:
- uses: actions/checkout@v1
with:
fetch-depth: 1
submodules: 'true'
- name: build ios
run: |
qmake -r -spec macx-ios-clang CONFIG+=release CONFIG+=iphoneos
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/macos-11_0.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ jobs:
- uses: actions/checkout@v1
with:
fetch-depth: 1
submodules: 'true'
- name: build macos
run: |
qmake
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ jobs:
- uses: actions/checkout@v1
with:
fetch-depth: 1
submodules: 'true'
- name: build macos
run: |
qmake
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ jobs:
- uses: actions/checkout@v1
with:
fetch-depth: 1
submodules: 'true'
- name: build ubuntu
run: |
qmake
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ jobs:
- uses: actions/checkout@v1
with:
fetch-depth: 1
submodules: 'true'
# msvc编译
- name: msvc-build
id: build
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "3rdparty/TaoCommon"]
path = 3rdparty/TaoCommon
url = https://github.com/jaredtao/TaoCommon.git
3 changes: 2 additions & 1 deletion 3rdparty/3rdparty.pri
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
include($$PWD/TaoCommon/TaoCommon.pri)
include($$PWD/TaoCommon/src/TaoCommon.pri)

1 change: 1 addition & 0 deletions 3rdparty/TaoCommon
Submodule TaoCommon added at c3f33c
9 changes: 9 additions & 0 deletions README-zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,15 @@ CusConfig是核心库的全局配置,主要包括字体、颜色等,所有组件

# 使用核心库TaoQuick

## 获取代码

```shell
git clone https://githun.com/jaredtao/TaoQuick.git
cd TaoQuick
git submodule update
```


详细的使用方法,可以阅读 [入门指南](入门指南.md)

## qmake用法
Expand Down
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,13 @@ Other Contents reference to above table:

# Use TaoQuick

## get code
```shell
git clone https://githun.com/jaredtao/TaoQuick.git
cd TaoQuick
git submodule update
```

## qmake

You just need import '.pri' file to project and add import Path to QmlEngine, TaoQuick will be use as local file or qrc resource.
Expand Down
12 changes: 9 additions & 3 deletions examples/TaoQuickShow/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,15 @@ aux_source_directory(Src/DeviceAddTable SRC2)
include(taoVersion)

add_compile_definitions(TaoCommon_NO_LIB)
add_subdirectory(${CMAKE_SOURCE_DIR}/3rdparty/TaoCommon ${CMAKE_SOURCE_DIR}/build/3rdparty/TaoCommon)
#message("TaoCommonPath ${TaoCommonPath}")
#message("TaoCommonFiles ${TaoCommonFiles}")
if (EXISTS ${CMAKE_SOURCE_DIR}/3rdparty/TaoCommon/src/TaoCommon)
add_subdirectory(${CMAKE_SOURCE_DIR}/3rdparty/TaoCommon/src/TaoCommon ${CMAKE_SOURCE_DIR}/build/3rdparty/TaoCommon)
#message("TaoCommonPath ${TaoCommonPath}")
#message("TaoCommonFiles ${TaoCommonFiles}")
else()
message(FATAL_ERROR "3rdparty library TaoCommon missing, please update by command: git submodule update")
endif()



include(taoQuick)
message("TaoQuickRes ${TaoQuickRes}")
Expand Down
6 changes: 4 additions & 2 deletions examples/TaoQuickShow/TaoQuickShow.pro
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,10 @@ CONFIG(debug,debug|release) {
} else {
DESTDIR = $${TaoQuick_RUN_TREE}/release
}

include($${TaoQuick_3RDPARTY_TREE}/TaoCommon/TaoCommon.pri)
!exists($${TaoQuick_3RDPARTY_TREE}/TaoCommon/src/TaoCommon/TaoCommon.pri) {
error("3rdparty library TaoCommon missing, please update by command: git submodule update")
}
include($${TaoQuick_3RDPARTY_TREE}/TaoCommon/src/TaoCommon/TaoCommon.pri)
include($${TaoQuick_SOURCE_TREE}/src/TaoQuick/imports/imports.pri)
include(TaoQuickShow.pri)
DEFINES += QMAKE_GEN_TAOMACRO
Expand Down

0 comments on commit 28f15f3

Please sign in to comment.