Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
M
Magisk
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
Magisk
Commits
b127e018
Commit
b127e018
authored
Sep 28, 2018
by
topjohnwu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Simplify debug flag propagation
parent
2118beeb
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
6 deletions
+9
-6
build.py
build.py
+3
-2
build.gradle
native/build.gradle
+1
-2
Application.mk
native/jni/Application.mk
+5
-2
No files found.
build.py
View file @
b127e018
...
@@ -173,8 +173,9 @@ def build_binary(args):
...
@@ -173,8 +173,9 @@ def build_binary(args):
os
.
utime
(
os
.
path
.
join
(
'native'
,
'jni'
,
'include'
,
'flags.h'
))
os
.
utime
(
os
.
path
.
join
(
'native'
,
'jni'
,
'include'
,
'flags.h'
))
# Basic flags
# Basic flags
base_flags
=
'MAGISK_VERSION=
\"
{}
\"
MAGISK_VER_CODE={} MAGISK_DEBUG={}'
.
format
(
config
[
'version'
],
config
[
'versionCode'
],
base_flags
=
'MAGISK_VERSION=
\"
{}
\"
MAGISK_VER_CODE={}'
.
format
(
config
[
'version'
],
config
[
'versionCode'
])
''
if
args
.
release
else
'-DMAGISK_DEBUG'
)
if
not
args
.
release
:
base_flags
+=
' MAGISK_DEBUG=1'
if
'magisk'
in
args
.
target
:
if
'magisk'
in
args
.
target
:
# Magisk is special case as it is a dependency of magiskinit
# Magisk is special case as it is a dependency of magiskinit
...
...
native/build.gradle
View file @
b127e018
...
@@ -14,8 +14,7 @@ android {
...
@@ -14,8 +14,7 @@ android {
externalNativeBuild
{
externalNativeBuild
{
ndkBuild
{
ndkBuild
{
// Pass arguments to ndk-build.
// Pass arguments to ndk-build.
arguments
(
'B_MAGISK=1'
,
'B_INIT=1'
,
'B_BOOT=1'
,
'B_BXZ=1'
,
arguments
(
'B_MAGISK=1'
,
'B_INIT=1'
,
'B_BOOT=1'
,
'B_BXZ=1'
,
'MAGISK_DEBUG=1'
)
'MAGISK_DEBUG=-DMAGISK_DEBUG'
)
}
}
}
}
}
}
...
...
native/jni/Application.mk
View file @
b127e018
APP_ABI := armeabi-v7a x86
APP_ABI := armeabi-v7a x86
APP_CFLAGS := -std=gnu11 ${MAGISK_DEBUG} \
APP_CFLAGS := -std=gnu11 -DMAGISK_VERSION="${MAGISK_VERSION}" -DMAGISK_VER_CODE=${MAGISK_VER_CODE}
-DMAGISK_VERSION="${MAGISK_VERSION}" -DMAGISK_VER_CODE=${MAGISK_VER_CODE}
APP_CPPFLAGS := -std=c++14
APP_CPPFLAGS := -std=c++14
APP_STL := system
APP_STL := system
APP_PLATFORM := android-16
APP_PLATFORM := android-16
ifdef MAGISK_DEBUG
APP_CFLAGS += -DMAGISK_DEBUG
endif
# Busybox require some additional settings
# Busybox require some additional settings
ifdef B_BB
ifdef B_BB
APP_SHORT_COMMANDS := true
APP_SHORT_COMMANDS := true
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment