Create gbs-build-p4.yml
author백종민/Tizen Platform Lab(SR)/삼성전자 <jm0829.baek@samsung.com>
Tue, 4 Jul 2023 01:09:41 +0000 (10:09 +0900)
committerGitHub Enterprise <noreply-CODE@samsung.com>
Tue, 4 Jul 2023 01:09:41 +0000 (10:09 +0900)
.github/workflows/gbs-build-p4.yml [new file with mode: 0644]

diff --git a/.github/workflows/gbs-build-p4.yml b/.github/workflows/gbs-build-p4.yml
new file mode 100644 (file)
index 0000000..9eb058f
--- /dev/null
@@ -0,0 +1,78 @@
+# This is a basic workflow to help you get started with Actions
+
+name: gbs-build
+
+# Controls when the workflow will run
+on:
+  pull_request:
+  push:
+    branches: 
+      - main
+
+  # 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:
+  gbs-build-p4:
+    runs-on: [code-default]
+    container:
+      image: actions-docker.bart.sec.samsung.net/docker-gbs-base
+      options: --user root --privileged
+    
+    env:
+      P4PORT: ${{ secrets.P4PORT }}
+      P4USER: ${{ secrets.P4USER }}
+
+    # Steps represent a sequence of tasks that will be executed as part of the job
+    steps:
+      - name: P4 setup
+        uses: perforce/setup-p4@v1
+        with:
+          p4_version: 21.2
+
+      - name: P4 login
+        uses: perforce/setup-p4@v1
+        with:
+          command: login
+        env:
+          P4PASSWD: ${{ secrets.P4PASSWD }}
+
+      # Create a workspace
+      - name: p4 client
+        uses: perforce/setup-p4@v1
+        with:
+          command: client
+          arguments: -i
+          spec: |
+            Client:    github-actions-setup-p4
+            Owner:     ${{ secrets.P4USER }}
+            Description:
+              Created by ${{ secrets.P4USER }}.
+            Root:      /tmp
+            Options:   noallwrite noclobber nocompress unlocked modtime rmdir
+            SubmitOptions:     leaveunchanged
+            LineEnd:   local
+            View:
+              //TIZEN/[MAIN]/[ONEPROD_Prj]/[DEV]/[PLATFORM]/[MMP_PPI_SRCN]/PPI/capi-trackrenderer-tv/... //github-actions-setup-p4/projects/TIZEN/ONEMAIN/DEV/PLATFORM/MMP_PPI_SRCN/PPI/capi-trackrenderer-tv/...
+          
+      # pull down assets from Helix Core
+      - name: p4 sync
+        uses: perforce/setup-p4@v1
+        env:
+          P4CLIENT: github-actions-setup-p4
+        with:
+          command: sync
+          
+      - name: Check binfmt_misc
+        run: |
+          ls -al /proc/sys/fs/binfmt_misc/
+          
+      - name: Switching off default binfmt_misc handlers
+        run: |
+          find /proc/sys/fs/binfmt_misc/ -not -name status -not -name register -type f -exec sh -c "echo -1 | sudo tee {}" \;
+      
+      - name: Build using tizen gbs
+        run: |
+          cd /tmp/TIZEN/ONEMAIN/DEV/PLATFORM/MMP_PPI_SRCN/PPI/capi-trackrenderer-tv/
+          gbs build -A armv7l -R ${{ secrets.BASE_REPO_URL }} -R ${{ secrets.PROD_REPO_URL }} --include-all --clean --incremental --define "enable_ut ON" --define "vd_gcov ON"