blueloveTH 1 год назад
Родитель
Сommit
0312dbc829
3 измененных файлов с 31 добавлено и 27 удалено
  1. 21 25
      .github/workflows/main.yml
  2. 5 1
      run_profile.sh
  3. 5 1
      run_tests.sh

+ 21 - 25
.github/workflows/main.yml

@@ -12,21 +12,17 @@ on:
       - 'web/**'
       - 'web/**'
       - '**.md'
       - '**.md'
 jobs:
 jobs:
-  build_win32_amalgamated:
-    runs-on: windows-latest
-    steps:
-    - uses: actions/checkout@v4
-    - uses: ilammy/msvc-dev-cmd@v1
-    - name: Compile
-      shell: powershell
-      run: |
-        python amalgamate.py
-        cd amalgamated
-        cl.exe /std:c++17 /EHsc /utf-8 /Ox /I. /DPK_ENABLE_OS=1 main.cpp /link /out:pkpy.exe
-    # - uses: actions/upload-artifact@v4
-    #   with:
-    #     name: amalgamated
-    #     path: amalgamated/pkpy.exe
+  # build_win32_amalgamated:
+  #   runs-on: windows-latest
+  #   steps:
+  #   - uses: actions/checkout@v4
+  #   - uses: ilammy/msvc-dev-cmd@v1
+  #   - name: Compile
+  #     shell: powershell
+  #     run: |
+  #       python amalgamate.py
+  #       cd amalgamated
+  #       cl.exe /std:c++17 /EHsc /utf-8 /Ox /I. /DPK_ENABLE_OS=1 main.cpp /link /out:pkpy.exe
   build_win32:
   build_win32:
     runs-on: windows-latest
     runs-on: windows-latest
     steps:
     steps:
@@ -109,16 +105,16 @@ jobs:
           python scripts/run_tests.py
           python scripts/run_tests.py
       - name: Benchmark
       - name: Benchmark
         run: python scripts/run_tests.py benchmark
         run: python scripts/run_tests.py benchmark
-      - run: |
-          python amalgamate.py
-          cd plugins/macos/pocketpy
-          mkdir output
-          xcodebuild clean build CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO
-          cp -r build/Release/pocketpy.bundle output
-      - uses: actions/upload-artifact@v4
-        with:
-          name: macos
-          path: plugins/macos/pocketpy/output
+      # - run: |
+      #     python amalgamate.py
+      #     cd plugins/macos/pocketpy
+      #     mkdir output
+      #     xcodebuild clean build CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO
+      #     cp -r build/Release/pocketpy.bundle output
+      # - uses: actions/upload-artifact@v4
+      #   with:
+      #     name: macos
+      #     path: plugins/macos/pocketpy/output
   build_android:
   build_android:
       runs-on: ubuntu-latest
       runs-on: ubuntu-latest
       steps:
       steps:

+ 5 - 1
run_profile.sh

@@ -1,5 +1,9 @@
 python prebuild.py
 python prebuild.py
-SRC=$(find src/ -name "*.cpp")
+
+SRC_C=$(find src/ -name "*.c")
+SRC_CPP=$(find src/ -name "*.cpp")
+SRC="$SRC_C $SRC_CPP"
+
 g++ -pg -Og -std=c++17 -frtti -Wfatal-errors -o main $SRC src2/main.cpp -Iinclude
 g++ -pg -Og -std=c++17 -frtti -Wfatal-errors -o main $SRC src2/main.cpp -Iinclude
 ./main benchmarks/fib.py
 ./main benchmarks/fib.py
 gprof main gmon.out > gprof.txt
 gprof main gmon.out > gprof.txt

+ 5 - 1
run_tests.sh

@@ -1,5 +1,9 @@
 python prebuild.py
 python prebuild.py
-SRC=$(find src/ -name "*.cpp")
+
+SRC_C=$(find src/ -name "*.c")
+SRC_CPP=$(find src/ -name "*.cpp")
+SRC="$SRC_C $SRC_CPP"
+
 clang++ -std=c++17 --coverage -O1 -stdlib=libc++ -frtti -Wfatal-errors -o main src2/main.cpp $SRC -Iinclude -DPK_ENABLE_OS=1 -DPK_DEBUG_PRECOMPILED_EXEC=1 -DPK_ENABLE_PROFILER=1
 clang++ -std=c++17 --coverage -O1 -stdlib=libc++ -frtti -Wfatal-errors -o main src2/main.cpp $SRC -Iinclude -DPK_ENABLE_OS=1 -DPK_DEBUG_PRECOMPILED_EXEC=1 -DPK_ENABLE_PROFILER=1
 
 
 python scripts/run_tests.py
 python scripts/run_tests.py