mirror of
https://github.com/vishapoberon/vipak.git
synced 2026-04-05 20:42:26 +00:00
updated build with newer posix makefile (thanks, kfv)
This commit is contained in:
parent
5659a3f155
commit
da7af58055
3 changed files with 9 additions and 139 deletions
65
makefile
65
makefile
|
|
@ -1,65 +0,0 @@
|
|||
mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST)))
|
||||
mkfile_dir_path := $(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
|
||||
build_dir_path := $(mkfile_dir_path)/build
|
||||
current_dir := $(notdir $(patsubst %/,%,$(dir $(mkfile_path))))
|
||||
BLD := $(mkfile_dir_path)/build
|
||||
|
||||
VOC = voc
|
||||
VERSION_FILE = ./VersionFile.json
|
||||
BLD = build
|
||||
DPS = dps
|
||||
VIPACK = vipack
|
||||
|
||||
|
||||
all: deps vipack
|
||||
|
||||
#git submodule init
|
||||
#git submodule update
|
||||
mkdir -p $(build_dir_path)
|
||||
cd $(build_dir_path)
|
||||
gmake -f $(mkfile_dir_path)/dps/lists/Makefile BUILD=$(build_dir_path)
|
||||
gmake -f $(mkfile_dir_path)/dps/Internet/makefile BUILD=$(build_dir_path)
|
||||
gmake -f $(mkfile_dir_path)/dps/time/Makefile BUILD=$(build_dir_path)
|
||||
gmake -f $(mkfile_dir_path)/dps/opts/Makefile BUILD=$(build_dir_path)
|
||||
vipack:
|
||||
cd $(build_dir_path) && \
|
||||
$(VOC) -s \
|
||||
../src/vpkSettings.Mod \
|
||||
../src/unix/vpkLinuxFiles.Mod \
|
||||
../src/unix/vpkTime.Mod \
|
||||
../src/vpkLogger.Mod \
|
||||
../src/vpkHttp.Mod \
|
||||
../src/unix/vpkEnv.Mod \
|
||||
../src/unix/vpkGit.Mod \
|
||||
../src/vpkCharacterStack.Mod \
|
||||
../src/vpkJsonParser.Mod \
|
||||
../src/vpkConf.Mod \
|
||||
../src/vpkStorage.Mod \
|
||||
../src/vpkSyncer.Mod \
|
||||
../src/vpkdepTree.Mod \
|
||||
../src/vpkDot.Mod \
|
||||
../src/vpkResolver.Mod \
|
||||
../src/vpkJsonDepRetriever.Mod \
|
||||
../src/vpkInstaller.Mod \
|
||||
../src/vipack.Mod -m
|
||||
|
||||
deps:
|
||||
mkdir -p $(mkfile_dir_path)/$(DPS)
|
||||
cd $(mkfile_dir_path)/$(DPS)
|
||||
if [ -d $(DPS)/Internet ]; then cd $(DPS)/Internet; git pull; cd -; else cd $(DPS); git clone https://github.com/norayr/Internet; cd -; fi
|
||||
if [ -d $(DPS)/lists ]; then cd $(DPS)/lists; git pull; cd -; else cd $(DPS); git clone https://github.com/norayr/lists; cd -; fi
|
||||
if [ -d $(DPS)/opts ]; then cd $(DPS)/opts; git pull; cd -; else cd $(DPS); git clone https://github.com/norayr/opts; cd -; fi
|
||||
if [ -d $(DPS)/time ]; then cd $(DPS)/time; git pull; cd -; else cd $(DPS); git clone https://github.com/norayr/time; cd -; fi
|
||||
|
||||
tests:
|
||||
mkdir -p $(mkfile_dir_path)/$(BLD)
|
||||
cd $(mkfile_dir_path)/$(BLD)
|
||||
$(VOC) -s ../src/unix/vpkLinuxFiles.Mod ../tst/testFiles.Mod -m
|
||||
cd $(BLD) && $(VOC) -s ../src/vpkJsonParser.Mod ../tst/testJsonParser.Mod -m
|
||||
mkfifo /tmp/fifo
|
||||
$(BLD)/testFiles
|
||||
rm /tmp/fifo
|
||||
$(BLD)/testJsonParser
|
||||
|
||||
clean:
|
||||
if [ -d "$(BLD)" ]; then rm -rf $(BLD); fi
|
||||
|
|
@ -1,65 +0,0 @@
|
|||
mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST)))
|
||||
mkfile_dir_path := $(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
|
||||
build_dir_path := $(mkfile_dir_path)/build
|
||||
current_dir := $(notdir $(patsubst %/,%,$(dir $(mkfile_path))))
|
||||
BLD := $(mkfile_dir_path)/build
|
||||
|
||||
VOC = voc
|
||||
VERSION_FILE = ./VersionFile.json
|
||||
BLD = build
|
||||
DPS = dps
|
||||
VIPACK = vipack
|
||||
|
||||
CFLAGS=
|
||||
|
||||
all: deps
|
||||
|
||||
#git submodule init
|
||||
#git submodule update
|
||||
mkdir -p $(build_dir_path)
|
||||
cd $(build_dir_path)
|
||||
gmake -f $(mkfile_dir_path)/dps/lists/makefile BUILD=$(build_dir_path)
|
||||
gmake -f $(mkfile_dir_path)/dps/Internet/makefile BUILD=$(build_dir_path)
|
||||
gmake -f $(mkfile_dir_path)/dps/time/makefile BUILD=$(build_dir_path)
|
||||
gmake -f $(mkfile_dir_path)/dps/opts/makefile BUILD=$(build_dir_path)
|
||||
cd $(build_dir_path) && \
|
||||
$(VOC) -s \
|
||||
../src/vpkSettings.Mod \
|
||||
../src/unix/vpkFreeBSDFiles.Mod \
|
||||
../src/unix/vpkTime.Mod \
|
||||
../src/vpkLogger.Mod \
|
||||
../src/vpkHttp.Mod \
|
||||
../src/unix/vpkEnv.Mod \
|
||||
../src/unix/vpkGit.Mod \
|
||||
../src/vpkCharacterStack.Mod \
|
||||
../src/vpkJsonParser.Mod \
|
||||
../src/vpkConf.Mod \
|
||||
../src/vpkStorage.Mod \
|
||||
../src/vpkSyncer.Mod \
|
||||
../src/vpkdepTree.Mod \
|
||||
../src/vpkDot.Mod \
|
||||
../src/vpkResolver.Mod \
|
||||
../src/vpkJsonDepRetriever.Mod \
|
||||
../src/vpkInstaller.Mod \
|
||||
../src/vipack.Mod -M
|
||||
|
||||
deps:
|
||||
mkdir -p $(mkfile_dir_path)/$(DPS)
|
||||
cd $(mkfile_dir_path)/$(DPS)
|
||||
if [ -d $(DPS)/Internet ]; then cd $(DPS)/Internet; git pull; cd -; else cd $(DPS); git clone https://github.com/norayr/Internet; cd -; fi
|
||||
if [ -d $(DPS)/lists ]; then cd $(DPS)/lists; git pull; cd -; else cd $(DPS); git clone https://github.com/norayr/lists; cd -; fi
|
||||
if [ -d $(DPS)/opts ]; then cd $(DPS)/opts; git pull; cd -; else cd $(DPS); git clone https://github.com/norayr/opts; cd -; fi
|
||||
if [ -d $(DPS)/time ]; then cd $(DPS)/time; git pull; cd -; else cd $(DPS); git clone https://github.com/norayr/time; cd -; fi
|
||||
|
||||
tests:
|
||||
mkdir -p $(mkfile_dir_path)/$(BLD)
|
||||
cd $(mkfile_dir_path)/$(BLD)
|
||||
$(VOC) -s ../src/unix/vpkFreeBSDFiles.Mod ../tst/testFiles.Mod -m
|
||||
cd $(BLD) && $(VOC) -s ../src/vpkJsonParser.Mod ../tst/testJsonParser.Mod -m
|
||||
mkfifo /tmp/fifo
|
||||
$(BLD)/testFiles
|
||||
rm /tmp/fifo
|
||||
$(BLD)/testJsonParser
|
||||
|
||||
clean:
|
||||
if [ -d "$(BLD)" ]; then rm -rf $(BLD); fi
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
MODULE vpkEnv;
|
||||
IMPORT Files, Platform, Strings, Out, vpkSettings, vpkFiles, StringList;
|
||||
IMPORT Files, Platform, Strings, Out, vpkSettings, vpkFiles, lDefs;
|
||||
|
||||
VAR
|
||||
conf, confDir : ARRAY 256 OF CHAR;
|
||||
|
|
@ -28,9 +28,9 @@ BEGIN
|
|||
|
||||
END createIfNotThere;
|
||||
|
||||
PROCEDURE getSrcRelPath*(VAR depName, path0: ARRAY OF CHAR): StringList.pstring;
|
||||
PROCEDURE getSrcRelPath*(VAR depName, path0: ARRAY OF CHAR): lDefs.pstring;
|
||||
VAR
|
||||
p: StringList.pstring;
|
||||
p: lDefs.pstring;
|
||||
len: INTEGER;
|
||||
BEGIN
|
||||
len := 9 + Strings.Length(depName) + Strings.Length(path0);
|
||||
|
|
@ -52,9 +52,9 @@ BEGIN
|
|||
Strings.Append(vpkSettings.vpkConfDir, path);
|
||||
END mkConfDirPath;
|
||||
|
||||
PROCEDURE mkBldDir*(VAR prefix: ARRAY OF CHAR): StringList.pstring;
|
||||
PROCEDURE mkBldDir*(VAR prefix: ARRAY OF CHAR): lDefs.pstring;
|
||||
VAR
|
||||
builddir: StringList.pstring;
|
||||
builddir: lDefs.pstring;
|
||||
ln : INTEGER;
|
||||
BEGIN
|
||||
ln := 3 + Strings.Length(prefix) + Strings.Length(vpkSettings.vpkBldDir);
|
||||
|
|
@ -68,9 +68,9 @@ BEGIN
|
|||
RETURN builddir
|
||||
END mkBldDir;
|
||||
|
||||
PROCEDURE mkdefBldDir*(): StringList.pstring;
|
||||
PROCEDURE mkdefBldDir*(): lDefs.pstring;
|
||||
VAR
|
||||
builddir: StringList.pstring;
|
||||
builddir: lDefs.pstring;
|
||||
ln: INTEGER;
|
||||
home: ARRAY 128 OF CHAR;
|
||||
BEGIN
|
||||
|
|
@ -118,9 +118,9 @@ BEGIN
|
|||
END mkPkgDirPath;
|
||||
|
||||
|
||||
PROCEDURE mkCmd*(VAR p0, p1: ARRAY OF CHAR): StringList.pstring;
|
||||
PROCEDURE mkCmd*(VAR p0, p1: ARRAY OF CHAR): lDefs.pstring;
|
||||
VAR
|
||||
cmd: StringList.pstring;
|
||||
cmd: lDefs.pstring;
|
||||
ln: INTEGER;
|
||||
BEGIN
|
||||
ln := 2 + Strings.Length(p0) + Strings.Length(p1);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue