diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 00000000..48fde874 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,44 @@ +# This is a basic workflow to help you get started with Actions + +name: CI + +# Controls when the workflow will run +on: + # Triggers the workflow on push or pull request events but only for the master branch + push: + branches: [ master ] + pull_request: + branches: [ master ] + + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains a single job called "build" + build: + # The type of runner that the job will run on + runs-on: ubuntu-latest + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it + - uses: actions/checkout@v2 + - uses: actions/setup-python@v1 + with: + python-version: '3.x' + - run: pip install meson ninja + - name: Install dependencies + run: sudo apt-get install -y libpango1.0-dev libxml2-dev + - run: meson setup _build + env: + CC: gcc + - name: Meson Build + run: meson compile -C _build + - name: Meson Test + run: meson test -C _build -v + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: Linux_Meson_Testlog + path: _build/meson-logs/testlog.txt diff --git a/itex2mml/meson.build b/itex2mml/meson.build index 3612f98e..bc74e2f9 100644 --- a/itex2mml/meson.build +++ b/itex2mml/meson.build @@ -3,10 +3,10 @@ flex = find_program('flex', required : true) yyprefix = 'itex2MML_yy' -y_tab_c = custom_target('bison y.tab.c', - output : 'y.tab.c', +y_tab = custom_target('bison y.tab.c', + output : ['y.tab.c', 'y.tab.h'], input : 'itex2MML.y', - command : [bison, '-v', '-p', yyprefix, '-d', '@INPUT@', '-o', '@OUTPUT@']) + command : [bison, '-v', '-p', yyprefix, '--defines=@OUTPUT1@', '--output=@OUTPUT0@', '@INPUT@']) lex_yy_c = custom_target('flex lex.yy.c', output : 'lex.yy.c', @@ -15,7 +15,7 @@ lex_yy_c = custom_target('flex lex.yy.c', libitex2mml_sources = [ 'itex2MML.h', - y_tab_c, + y_tab, lex_yy_c ]