3 EOS_GIT_BACKUPSITE=/net/fs08/fs08/DataBase/EosBackup.git
4 EOS_GIT_REPOSITRY= git.osdn.jp:/gitroot/eos/base.git
5 EOS_GIT_REPOSITRY_NOUSER=git://git.osdn.jp/gitroot/eos/base.git
6 EOS_GIT_REPOSITRY_OPTIONAL= git.osdn.jp:/gitroot/eos/optional.git
7 EOS_GIT_REPOSITRY_OPTIONAL_NOUSER=git://git.osdn.jp/gitroot/eos/optional.git
8 EOS_GIT_REPOSITRY_TUTORIAL= git.osdn.jp:/gitroot/eos/tutorial.git
9 EOS_GIT_REPOSITRY_TUTORIAL_NOUSER=git://git.osdn.jp/gitroot/eos/tutorial.git
10 EOS_GIT_REPOSITRY_DATA= git.osdn.jp:/gitroot/eos/data.git
11 EOS_GIT_REPOSITRY_DATA_NOUSER=git://git.osdn.jp/gitroot/eos/data.git
12 EOS_GIT_REPOSITRY_OTHERS= git.osdn.jp:/gitroot/eos/others.git
13 EOS_GIT_REPOSITRY_OTHERS_NOUSER=git://git.osdn.jp/gitroot/eos/others.git
16 EOS_GIT_REPOSITRY_HOSTDEPEND=git.osdn.jp:/gitroot/eos/hostdepend
17 EOS_GIT_REPOSITRY_HOSTDEPEND_NOUSER=git://git.osdn.jp/gitroot/eos/hostdepend
19 EOS_GIT_REPOSITRY_ZEPHYR= git.osdn.jp:/gitroot/eos/zephyr.git
20 EOS_GIT_REPOSITRY_ZEPHYR_NOUSER=git://git.osdn.jp/gitroot/eos/zephyr.git
22 EOS_GIT_REPOSITRY_PIONE=https://github.com/pione/pione.git
23 EOS_GIT_REPOSITRY_PIONE_NOUSER=https://github.com/pione/pione.git
28 @echo "---- To register new/Modified source codes. ----"
29 @echo " $$ make git-add or git-add[-all|-data|-tutorial|-optional|-others|-others2]"
30 @echo " $$ make git-commit or git-commit[-all|-data|-tutorial|-optional|-others|-others2]"
31 @echo " $$ make git-tag or git-tag[-all|-data|-tutorial|-optional|-others|-others2]"
32 @echo " $$ make git-push or git-push[-all|-data|-tutorial|-optional|-others]"
34 @echo "---- To fetch and merge new/modified source codes. ----"
35 @echo " $$ make git-fetch or git-fetch[-all|-data|-tutorial|-optional|-others]"
36 @echo " $$ make git-merge or git-merge[-all|-data|-tutorial|-optional|-others]"
37 @echo " $$ make setting"
38 @echo "---- To init git repository ----"
39 @echo " $$ make git-init or git-init[-all|-zephyr|-data|-tutorial|-optional|-others]"
40 @echo "---- To clonse git repository ----"
41 @echo " $$ make git-clone or git-clone[-all|-zephyr|-data|-tutorial|-optional|-others]"
42 @echo "---- option ----"
43 @echo " [] : base only"
44 @echo " [-zephyr] : zephyr (for GUI/browser)"
45 @echo " [-pione] : pione (for process control with GUI/browser)"
46 @echo " [-data] : data (for test)"
47 @echo " [-tutorial] : tutorial"
48 @echo " [-optional] : optional(for documents)"
49 @echo " [-others] : other source codes for utils"
50 @echo " [-others2] : other source codes for utils"
54 @echo "---- To set Eos ----"
55 @echo " $$ make setting ; # Create links."
56 @echo " $$ make install ; # No clean, just install."
57 @echo " $$ make rebuild ; # Clean and install."
58 @echo " $$ make rebuild-all ; # Update(prototype), clean and install."
61 @echo "---- To rebuild source codes of Eos ----"
62 @echo " $$ make rebuild"
63 @echo "---- To update prototype source codes and rebuild source codes of Eos ----"
64 @echo " $$ make rebuild-all"
65 @echo "---- To set Eos ----"
66 @echo " $$ make setting"
68 @echo ">>>> Setting for Eos utils using other softwares "
69 @echo "---- To set Eos ----"
70 @echo " $$ cd util; make setting"
71 @echo " $$ cd util; make rebuild"
75 rebuild-all: rebuild-src rebuild-Objects rebuild-all-Tools
76 rebuild: rebuild-src rebuild-Objects rebuild-Tools
84 cd src; rm -f Makefile; cp -f Config/Template/Makefile Makefile
85 cd src; rm -f Objects/Makefile; cp -f Config/Template/ObjectsHomeTemplate.Dir/Makefile Objects/Makefile; rm -f Objects/Config/Target.inc; cp -f Config/Template/ObjectsHomeTemplate.Dir/Config/Target.inc Objects/Config/Target.inc
86 cd src; rm -f Tools/Makefile; cp -f Config/Template/ToolsHomeTemplate.Dir/Makefile Tools/Makefile; rm -f Tools/Config/Target.inc ; cp -f Config/Template/ToolsHomeTemplate.Dir/Config/Target.inc Tools/Config/Target.inc
89 cd src/Objects; make clean; make check; make depend; make ; make install
92 cd src/Tools; make clean; make check; make depend; make ; make install
95 cd src/Tools; make clean; make update; make check; make depend; make ; make install
99 cd src; rm -f Objects/Makefile; cp -f Config/Template/ObjectsHomeTemplate.Dir/Makefile Objects/Makefile
100 cd src; rm -f Tools/Makefile; cp -f Config/Template/ToolsHomeTemplate.Dir/Makefile Tools/Makefile
103 @echo "install-Objects"
104 cd src/Objects; make check; make depend; make ; make install
107 @echo "install-Tools"
108 cd src/Tools; make check; make depend; make ; make install
111 if [ ! -d hostdepend] ; then \
116 ln -sf optional/doc .
117 ln -sf optional/objects .
118 ln -sf data/example .
124 git-add-all:: git-add git-add-data git-add-optional git-add-tutorial git-add-others
126 git-add:: git-add-hostdepend
127 @echo "base directory"
128 @git add -v --all . || echo "No files to be added"
131 @echo "hostdepend directory"
132 @cd hostdepend/$${EOS_HOSTDIR}/ ; FLAG=N; \
133 for name in `git remote`; do if [ $$name = hostdepend$${EOS_HOSTDIR} ] ; then FLAG=Y; fi; done; \
134 if [ $$FLAG = 'N' ] ; then \
135 git remote add hostdepend$${EOS_HOSTDIR} $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_HOSTDEPEND)$${EOS_HOSTDIR}.git || echo "Already exist"; \
137 @cd hostdepend/$${EOS_HOSTDIR}/ ; git add -v --all . || echo "No files to be added\n"
140 cd optional; git add -v --all .
143 cd data; git add -v --all .
146 cd tutorial; git add -v --all .
149 cd others; git add -v --all .
152 cd others2; git add --all .
158 git-commit-all:: git-commit git-commit-data git-commit-optional git-commit-tutorial git-commit-others
160 git-commit:: git-commit-hostdepend
161 @git commit || echo "Already commited"
163 git-commit-hostdepend::
164 @cd hostdepend/$${EOS_HOSTDIR}/ ; git commit || echo "Already commited"
166 git-commit-optional::
167 cd optional; git commit
172 git-commit-tutorial::
173 cd tutorial; git commit
176 cd others; git commit
179 cd others2; git commit
182 git push $(EOS_GIT_BACKUPSITE) master --tags
189 @export DIRECTORYNAME=./; \
193 @export DIRECTORYNAME=optional; \
197 @export DIRECTORYNAME=data; \
201 @export DIRECTORYNAME=tutorial; \
205 @export DIRECTORYNAME=others; \
209 @if [ ! -z "$$DIRECTORYNAME" ]; then \
210 cd $$DIRECTORYNAME; \
212 git tag | sort -k 2,2 -n -t p ; \
213 echo -n "Version No. (e.g. vXX.YY.ZZpSSSS) : "; \
215 if [ ! -z "$$TTT" ]; then \
226 git-push-all:: git-push git-push-data git-push-optional git-push-tutorial git-push-others
228 git-push::git-push-hostdepend
229 # git push origin master --tags
231 @export DIRECTORYNAME=./; \
232 export ORIGINNAME=origin; \
233 make git-push-with-check;
235 git-push-hostdepend::
236 # git subtree push --prefix=hostdepend/$${EOS_HOSTDIR}/ --squash hostdepend$${EOS_HOSTDIR} master
238 @cd hostdepend/$${EOS_HOSTDIR}/; git push hostdepend$${EOS_HOSTDIR} master
241 # cd optional; git push optional master --tags
242 @export DIRECTORYNAME=optional; \
243 export ORIGINNAME=optional; \
244 make git-push-with-check;
247 # cd data; git push data master --tags
248 @export DIRECTORYNAME=data; \
249 export ORIGINNAME=data; \
250 make git-push-with-check;
253 # cd tutorial; git push tutorial master --tags
254 @export DIRECTORYNAME=tutorial; \
255 export ORIGINNAME=tutorial; \
256 make git-push-with-check;
259 # cd others; git push others master --tags
260 @export DIRECTORYNAME=others; \
261 export ORIGINNAME=others; \
262 make git-push-with-check;
264 git-push-with-check::
265 @if [ ! -z "$$DIRECTORYNAME" -a ! -z "$$ORIGINNAME" ]; then \
266 cd $$DIRECTORYNAME; \
268 SSS=`git tag | sort -k 2,2 -n -t p | tail -1`; \
269 if [ ! -z "$$SSS" ]; then \
270 echo "$$SSS is Current Tags in $$ORIGINNAME."; \
271 echo -n "Was the current tag updated? [ Y|y | N|n ]: "; \
273 if [ "$$TTT" = Y -o "$$TTT" = y ]; then \
274 git push $$ORIGINNAME master --tags; \
279 echo "Tags do not exist in $$ORIGINNAME."; \
280 echo "Before push please add tag at current repositry."; \
287 git-fetch-all:: git-fetch fit-fetch-zephyr git-fetch-data git-fetch-optional git-fetch-tutorial git-fetch-others
289 git-fetch::git-pull-hostdepend
290 @echo "fetch: base directory"
291 @cd . ; git fetch origin master --tags ; git log -1 || echo "No files to be fetched"
293 git-pull-hostdepend::
294 @#git subtree pull --prefix=hostdepend/$${EOS_HOSTDIR}/ --squash hostdepend$${EOS_HOSTDIR} master
295 @echo "pull: hostdepend directory"
296 @#cd hostdepend/$${EOS_HOSTDIR}/; git pull --unshallow hostdepend$${EOS_HOSTDIR} master || echo "No files to be fetched"
297 @cd hostdepend/$${EOS_HOSTDIR}/; git pull hostdepend$${EOS_HOSTDIR} master || echo "No files to be fetched"
300 cd zephyr; git fetch zephyr master --tags ; git log -1
303 cd data ; git fetch data master --tags ; git log -1
306 cd optional; git fetch optional master --tags ; git log -1
309 cd tutorial; git fetch tutorial master --tags ; git log -1
312 cd others ; git fetch others master --tags ; git log -1
317 git-merge-all:: git-merge git-merge-zephyr git-merge-data git-merge-optional git-merge-tutorial git-merge-others
320 cd . ; git log -1; git merge FETCH_HEAD
323 cd zephyr ; git log -1; git merge FETCH_HEAD
326 cd data ; git log -1; git merge FETCH_HEAD
329 cd optional; git log -1; git merge FETCH_HEAD
332 cd tutorial; git log -1; git merge FETCH_HEAD
335 cd others ; git log -1; git merge FETCH_HEAD
342 git-init-all:: git-init git-init-zephyr git-init-data git-init-optional git-init-tutorial git-init-others
344 git-init:: git-add-hostdepend
345 if [ ! -d .git ] ; then git init ; fi
346 @export ORIGINNAME=origin; \
350 if [ ! -d data ] ; then mkdir data; fi
352 if [ ! -d .git ] ; then git init ; fi ;
353 @export ORIGINNAME=data; \
354 make git-remote-add-data;
357 if [ ! -d zephyr ] ; then mkdir zephyr ; fi
359 if [ ! -d .git ] ; then git init ; fi ;
360 @export ORIGINNAME=zephyr; \
361 make git-remote-add-zephyr;
364 if [ ! -d pione ] ; then mkdir pione; fi
366 if [ ! -d .git ] ; then git init ; fi ;
367 @export ORIGINNAME=pione; \
368 make git-remote-add-pione;
371 if [ ! -d optional ] ; then mkdir optional; fi
372 if [ ! -L doc ] ; then ln -sf optional/doc . ; fi
373 if [ ! -L objects ] ; then ln -sf optional/objects . ; fi
375 if [ ! -d .git ] ; then git init ; fi ;
376 @export ORIGINNAME=optional; \
377 make git-remote-add-optional;
380 if [ ! -d tutorial ] ; then mkdir tutorial ; fi
382 if [ ! -d .git ] ; then git init ; fi ;
383 @export ORIGINNAME=tutorial; \
384 make git-remote-add-tutorial;
387 if [ ! -d others ] ; then mkdir others; fi
389 if [ ! -d .git ] ; then git init ; fi ;
390 @export ORIGINNAME=others; \
391 make git-remote-add-others;
394 if [ ! -d others2 ] ; then mkdir others2; fi
395 cd others2 ; git remote add others2 $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_OTHERS)
399 git-clone-all:: git-clone
400 @if [ ! -z "$${EOS_HOME}" -a -d "$${EOS_HOME}" ] ; then \
402 make git-clone-data git-clone-optional git-clone-tutorial git-clone-others; \
406 @if [ ! -z "$${EOS_HOME}" -a -d "$${EOS_HOME}" ] ; then \
407 TMPDIRECTORY=$$(pwd) ; \
411 if [ -z $${EOS_GITUSER} ] ; then \
412 git clone --depth 1 $(EOS_GIT_REPOSITRY_NOUSER) ./ ; \
414 git clone --depth 1 $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY) ./ ; \
416 cd $${TMPDIRECTORY}; \
417 export ORIGINNAME=origin; \
418 make git-remote-add; \
423 if [ ! -d zephyr] ; then mkdir zephyr; fi
424 @cd zephyr; if [ ! -d .git ] ; \
426 if [ -z $${EOS_GITUSER} ] ; then \
427 git clone --depth 1 $(EOS_GIT_REPOSITRY_ZEPHYR_NOUSER) ./ ; \
429 git clone --depth 1 $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_ZEPHYR) ./; \
432 export ORIGINNAME=zephyr; \
433 make git-remote-add-zephyr; \
437 if [ ! -d data ] ; then mkdir data; fi
438 @cd data; if [ ! -d .git ] ; \
440 if [ -z $${EOS_GITUSER} ] ; then \
441 git clone --depth 1 $(EOS_GIT_REPOSITRY_DATA_NOUSER) ./ ; \
443 git clone --depth 1 $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_DATA) ./; \
446 export ORIGINNAME=data; \
447 make git-remote-add-data; \
451 if [ ! -d optional ] ; then mkdir optional; fi
452 if [ ! -L doc ] ; then ln -sf optional/doc . ; fi
453 if [ ! -L objects ] ; then ln -sf optional/objects . ; fi
454 @cd optional; if [ ! -d .git ] ; \
456 if [ -z $${EOS_GITUSER} ] ; then \
457 git clone --depth 1 $(EOS_GIT_REPOSITRY_OPTIONAL_NOUSER) ./ ; \
459 git clone --depth 1 $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_OPTIONAL) ./ ; \
462 export ORIGINNAME=optional; \
463 make git-remote-add-optional; \
467 if [ ! -d tutorial ] ; then mkdir tutorial ; fi
468 @cd tutorial; if [ ! -d .git ] ; \
470 if [ -z $${EOS_GITUSER} ] ; then \
471 git clone --depth 1 $(EOS_GIT_REPOSITRY_TUTORIAL_NOUSER) ./ ; \
473 git clone --depth 1 $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_TUTORIAL) ./ ; \
476 export ORIGINNAME=tutorial; \
477 make git-remote-add-tutorial; \
481 if [ ! -d others ] ; then mkdir others; fi
482 @cd others ; if [ ! -d .git ] ; \
484 if [ -z $${EOS_GITUSER} ] ; then \
485 git clone --depth 1 $(EOS_GIT_REPOSITRY_OTHERS_NOUSER) ./ ; \
487 git clone --depth 1 $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_OTHERS) ./ ; \
490 export ORIGINNAME=others; \
491 make git-remote-add-others; \
497 @if [ ! -z "$$ORIGINNAME" -a ! -z "$${EOS_HOME}" -a -d "$${EOS_HOME}" ]; then \
499 SSS=`git remote -v | awk '{print $$1}' | grep origin`; if [ ! -z "$$SSS" ] ; then git remote rm origin ; fi ; \
500 if [ -z $${EOS_GITUSER} ] ; then \
501 git remote add origin $(EOS_GIT_REPOSITRY_NOUSER); \
503 git remote add origin $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY); \
507 git-remote-add-zephyr::
508 @if [ ! -z "$$ORIGINNAME" ]; then \
510 SSS=`git remote -v | awk '{print $$1}' | grep data`; if [ ! -z "$$SSS" ] ; then git remote rm zephyr; fi ; \
511 if [ -z $${EOS_GITUSER} ] ; then \
512 git remote add zephyr $(EOS_GIT_REPOSITRY_ZEPHYR_NOUSER); \
514 git remote add zephyr $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_ZEPHYR); \
518 git-remote-add-data::
519 @if [ ! -z "$$ORIGINNAME" ]; then \
521 SSS=`git remote -v | awk '{print $$1}' | grep data`; if [ ! -z "$$SSS" ] ; then git remote rm data ; fi ; \
522 if [ -z $${EOS_GITUSER} ] ; then \
523 git remote add data $(EOS_GIT_REPOSITRY_DATA_NOUSER); \
525 git remote add data $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_DATA); \
529 git-remote-add-optional::
530 @if [ ! -z "$$ORIGINNAME" ]; then \
532 SSS=`git remote -v | awk '{print $$1}' | grep optional`; if [ ! -z "$$SSS" ] ; then git remote rm optional ; fi ; \
533 if [ -z $${EOS_GITUSER} ] ; then \
534 git remote add optional $(EOS_GIT_REPOSITRY_OPTIONAL_NOUSER); \
536 git remote add optional $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_OPTIONAL); \
540 git-remote-add-tutorial::
541 @if [ ! -z "$$ORIGINNAME" ]; then \
543 SSS=`git remote -v | awk '{print $$1}' | grep tutorial`; if [ ! -z "$$SSS" ] ; then git remote rm tutorial ; fi ; \
544 if [ -z $${EOS_GITUSER} ] ; then \
545 git remote add tutorial $(EOS_GIT_REPOSITRY_TUTORIAL_NOUSER); \
547 git remote add tutorial $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_TUTORIAL); \
551 git-remote-add-others::
552 @if [ ! -z "$$ORIGINNAME" ]; then \
554 SSS=`git remote -v | awk '{print $$1}' | grep others`; if [ ! -z "$$SSS" ] ; then git remote rm others ; fi ; \
555 if [ -z $${EOS_GITUSER} ] ; then \
556 git remote add others $(EOS_GIT_REPOSITRY_OTHERS_NOUSER); \
558 git remote add others $${EOS_GITUSER}@$(EOS_GIT_REPOSITRY_OTHERS); \