libs-dev: makefiles

git-svn-id: svn://kolibrios.org@1023 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Mihail Semenyako (mike.dld) 2009-02-04 12:27:53 +00:00
parent 7c08af0706
commit 56356c8065
2 changed files with 58 additions and 0 deletions

View File

@ -0,0 +1,28 @@
@echo off
set LIBPREFIX=lib
set LIBEXT=obj
set TESTPREFIX=test
echo building libraries...
if exist bin rmdir /S /Q bin
mkdir bin
for %%i in (gfx img ini io) do (
echo %LIBPREFIX%%%i
cd %LIBPREFIX%%%i
fasm %LIBPREFIX%%%i.asm ..\bin\%LIBPREFIX%%%i.%LIBEXT% >nul
cd ..
)
echo building tests...
mkdir bin\.test
for %%i in (001 002) do (
echo %%i
cd .test\%%i
fasm %TESTPREFIX%%%i.asm ..\..\bin\.test\%TESTPREFIX%%%i >nul
cd ..\..
)

View File

@ -0,0 +1,30 @@
LIBPREFIX=lib
LIBEXT=obj
TESTPREFIX=test
.PHONY: all
all: libraries tests
libraries:
@echo "building libraries..."
@mkdir -p bin
@for i in gfx img ini io; do \
echo " $(LIBPREFIX)$${i}"; \
cd "$(LIBPREFIX)$${i}"; \
fasm "$(LIBPREFIX)$${i}.asm" "../bin/$(LIBPREFIX)$${i}.$(LIBEXT)" >/dev/null; \
cd ..; \
done
tests:
@echo "building tests..."
@mkdir -p bin/.test
@for i in 001 002; do \
echo " $${i}"; \
cd ".test/$${i}"; \
fasm "$(TESTPREFIX)$${i}.asm" "../../bin/.test/$(TESTPREFIX)$${i}" >/dev/null; \
cd ../..; \
done
clean:
rm -rf bin