Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
961a493a
Commit
961a493a
authored
Jul 24, 2020
by
houkime
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dirs: better arithmetics and shorter code
parent
4e655bd3
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
25 deletions
+5
-25
src/tools/pwre/src/dir_symbols.mk
src/tools/pwre/src/dir_symbols.mk
+5
-25
No files found.
src/tools/pwre/src/dir_symbols.mk
View file @
961a493a
...
...
@@ -4,20 +4,6 @@ comma := ,
empty
:=
space
:=
$(empty)
$(empty)
pred_13
:=
12
pred_12
:=
11
pred_11
:=
10
pred_10
:=
9
pred_9
:=
8
pred_8
:=
7
pred_7
:=
6
pred_6
:=
5
pred_5
:=
4
pred_4
:=
3
pred_3
:=
2
pred_2
:=
1
pred_1
:=
0
cwd_dirs
:=
$(
subst
/,
$(space)
,
$(PWD)
)
#cwd_dirs := $(subst .hw_,hw_,$(cwd_dirs))
#cwd_dirs := $(subst .os_,os_,$(cwd_dirs))
...
...
@@ -30,7 +16,7 @@ word := $(words $(cwd_dirs))
#prev := pred_ $(word)
#pred := $(subst $(space),$(empty),$(prev))
#word := $(
$(pred)
)
#word := $(
shell expr $(word) - 1
)
#os_name := $(word $(word), $(cwd_dirs))
#ifneq ($(findstring os,$(os_name)),os)
#include ___error___os
...
...
@@ -38,23 +24,17 @@ word := $(words $(cwd_dirs))
#prev := pred_ $(word)
#pred := $(subst $(space),$(empty),$(prev))
#word := $(
$(pred)
)
#word := $(
shell expr $(word) - 1
)
src_name
:=
$(
word
$(word)
,
$(cwd_dirs)
)
#ifneq ($(src_name),src)
#include ___error___no_source_subdirectory
#endif
prev
:=
pred_
$(word)
pred
:=
$(
subst
$(space)
,
$(empty)
,
$(prev)
)
word
:=
$
(
$(pred)
)
word
:=
$(
shell
expr
$(word)
- 1
)
comp_name
:=
$(
word
$(word)
,
$(cwd_dirs)
)
prev
:=
pred_
$(word)
pred
:=
$(
subst
$(space)
,
$(empty)
,
$(prev)
)
word
:=
$
(
$(pred)
)
word
:=
$(
shell
expr
$(word)
- 1
)
type_name
:=
$(
word
$(word)
,
$(cwd_dirs)
)
prev
:=
pred_
$(word)
pred
:=
$(
subst
$(space)
,
$(empty)
,
$(prev)
)
word
:=
$
(
$(pred)
)
word
:=
$(
shell
expr
$(word)
- 1
)
root_name
:=
$(
word
$(word)
,
$(cwd_dirs)
)
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