Browse Source

switch computers

main
heck 2 years ago
parent
commit
cfc397dda4
  1. 13
      Makefile
  2. 7
      Makefile.conf
  3. 7
      README.md
  4. 0
      compilers/RecipeLangToMakrdown.ysl2
  5. 3
      language/RecipeLang.yml2
  6. 9
      src/Makefile

13
Makefile

@ -0,0 +1,13 @@
.PHONY: all test src clean
all: src
src:
$(MAKE) -C src
#test:
# $(MAKE) -C test
clean:
$(MAKE) -C src clean
# $(MAKE) -C test clean

7
Makefile.conf

@ -0,0 +1,7 @@
DSLNAME=RecipeLang
YML_PATH+=:$(realpath ../grammar)
COMPILER=$(realpath compiler/$(DSLNAME).ysl2)
BUILD_DIR=./build

7
README.md

@ -4,10 +4,13 @@ Hello world style template-project to create
a DSL in yml2 a DSL in yml2
project template featuring: project template featuring:
* dir structure * project organisation
* build system * build system
* incremental builds * incremental builds*
* TODO: tests
We create a new language `RecipeLang` to describe cooking recipes.
The language consists of

0
compiler/RecipeLang.ysl2 → compilers/RecipeLangToMakrdown.ysl2

3
grammar/RecipeLang.yml2 → language/RecipeLang.yml2

@ -1,4 +1,5 @@
// Example language grammar // Language grammar
// for example language RecipeLang
DSLName { DSLName {
dls_data { dls_data {

9
src/Makefile

@ -1,11 +1,4 @@
# TODO: include ../Makefile.conf
# Incremental compilation impossible without redundantly specifying
# files that will be generated in the makefile
DSLNAME=RecipeLang
YML_PATH+=:../grammar
COMPILER=../compiler/$(DSLNAME).ysl2
BUILD_DIR=./build
SRC=$(wildcard *.$(DSLNAME)) SRC=$(wildcard *.$(DSLNAME))
SRC_XML=$(addsuffix .xml, $(basename $(SRC))) SRC_XML=$(addsuffix .xml, $(basename $(SRC)))

Loading…
Cancel
Save