fix qtmoc

This commit is contained in:
therecipe 2017-03-23 18:05:27 +01:00
parent b470027a32
commit 6bcfb21c9a
5 changed files with 12 additions and 4 deletions

View file

@ -240,7 +240,7 @@ You should run `qtsetup` after each upgrade.
3. Install the SDK dependencies with `C:\android-sdk-windows\tools\android.bat` or `$HOME/android-sdk-{ macosx | linux }/tools/android`
* Tools
* Android SDK Build-tools (25.0.4)
* Android SDK Build-tools (25.0.2)
* Android 7.1.1 (API 25)
* SDK Platform
* Extras (Windows only)

View file

@ -384,6 +384,11 @@ func SortedClassNamesForModule(module string, template bool) []string {
for item, dep := range items {
cd, ok := State.ClassMap[dep]
if !ok{
delete(items, item)
continue
}
if ok && !(cd.Module == MOC || strings.HasPrefix(cd.Module, "custom_")) || cd.Name == mostBase(items) {
tmpOutput = append(tmpOutput, item)
delete(items, item)

View file

@ -74,7 +74,7 @@ func android_config(path, depPath string) string {
}{
Qt: filepath.Join(utils.QT_DIR(), utils.QT_VERSION_MAJOR(), "android_armv7"),
Sdk: utils.ANDROID_SDK_DIR(),
SdkBuildToolsRevision: "25.0.4",
SdkBuildToolsRevision: "25.0.2",
Ndk: utils.ANDROID_NDK_DIR(),
Toolchainprefix: "arm-linux-androideabi",
Toolprefix: "arm-linux-androideabi",

View file

@ -18,6 +18,8 @@ import (
"github.com/therecipe/qt/internal/utils"
)
var done = make(map[string]struct{})
func Moc(path, target string) {
utils.Log.WithField("path", path).WithField("target", target).Debug("start Moc")
@ -31,7 +33,8 @@ func Moc(path, target string) {
continue
}
if i > 0 {
if _, ok := done[path]; !ok && i > 0 {
done[path] = struct{}{}
Moc(path, target)
}

View file

@ -17,7 +17,7 @@ func GetImports(path string, level int) []string {
var imports []string
level++
if level > 5 {
if level > 10 {
return imports
}