mirror of
				https://github.com/Perlmint/glew-cmake.git
				synced 2025-11-04 14:16:47 +00:00 
			
		
		
		
	Compare commits
	
		
			2 Commits
		
	
	
		
			48549018bc
			...
			7c15704efa
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						 | 
					7c15704efa | ||
| 
						 | 
					b87539999f | 
							
								
								
									
										114
									
								
								.github/workflows/cmake.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										114
									
								
								.github/workflows/cmake.yml
									
									
									
									
										vendored
									
									
								
							@ -18,10 +18,6 @@ env:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
jobs:
 | 
					jobs:
 | 
				
			||||||
  build:
 | 
					  build:
 | 
				
			||||||
    # The CMake configure and build commands are platform agnostic and should work equally
 | 
					 | 
				
			||||||
    # well on Windows or Mac.  You can convert this to a matrix build if you need
 | 
					 | 
				
			||||||
    # cross-platform coverage.
 | 
					 | 
				
			||||||
    # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
 | 
					 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    container: ubuntu:latest
 | 
					    container: ubuntu:latest
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -91,87 +87,75 @@ jobs:
 | 
				
			|||||||
        cmake .
 | 
					        cmake .
 | 
				
			||||||
        cmake --build .
 | 
					        cmake --build .
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  build_2_8:
 | 
					  build_linux:
 | 
				
			||||||
    # The CMake configure and build commands are platform agnostic and should work equally
 | 
					    strategy:
 | 
				
			||||||
    # well on Windows or Mac.  You can convert this to a matrix build if you need
 | 
					      fail-fast: false
 | 
				
			||||||
    # cross-platform coverage.
 | 
					      matrix:
 | 
				
			||||||
    # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
 | 
					        cmake:
 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					          - 2.8.12.2
 | 
				
			||||||
    container: ubuntu:14.04
 | 
					          - 3.10.3
 | 
				
			||||||
 | 
					          - latest
 | 
				
			||||||
    steps:
 | 
					 | 
				
			||||||
    - uses: actions/checkout@v2
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
    - name: Install dependencies
 | 
					 | 
				
			||||||
      run: apt update && apt install -y cmake gcc libgl1-mesa-dev libx11-dev libxext-dev
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    - name: Configure CMake
 | 
					 | 
				
			||||||
      shell: bash
 | 
					 | 
				
			||||||
      run: cmake . -DCMAKE_BUILD_TYPE=$BUILD_TYPE
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    - name: Build test
 | 
					 | 
				
			||||||
      shell: bash
 | 
					 | 
				
			||||||
      run: cmake --build .
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    - name: Check alias
 | 
					 | 
				
			||||||
      shell: bash
 | 
					 | 
				
			||||||
      run: test -e lib/libGLEW.a
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  build_3_10:
 | 
					 | 
				
			||||||
    # The CMake configure and build commands are platform agnostic and should work equally
 | 
					 | 
				
			||||||
    # well on Windows or Mac.  You can convert this to a matrix build if you need
 | 
					 | 
				
			||||||
    # cross-platform coverage.
 | 
					 | 
				
			||||||
    # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
 | 
					 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					 | 
				
			||||||
    container: ubuntu:18.04
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    steps:
 | 
					 | 
				
			||||||
    - uses: actions/checkout@v2
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
    - name: Install dependencies
 | 
					 | 
				
			||||||
      run: apt update && apt install -y cmake gcc libgl1-mesa-dev libx11-dev libxext-dev
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    - name: Configure CMake
 | 
					 | 
				
			||||||
      shell: bash
 | 
					 | 
				
			||||||
      run: cmake . -DCMAKE_BUILD_TYPE=$BUILD_TYPE
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    - name: Build test
 | 
					 | 
				
			||||||
      shell: bash
 | 
					 | 
				
			||||||
      run: cmake --build .
 | 
					 | 
				
			||||||
      
 | 
					 | 
				
			||||||
    - name: Check alias
 | 
					 | 
				
			||||||
      shell: bash
 | 
					 | 
				
			||||||
      run: test -e lib/libGLEW.a
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  build_latest:
 | 
					 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    container: ubuntu:latest
 | 
					    container: ubuntu:latest
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
    - uses: actions/checkout@v2
 | 
					    - uses: actions/checkout@v2
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    - name: Restore cached cmake
 | 
				
			||||||
 | 
					      uses: actions/cache/restore@v4
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        path: /opt/cmake
 | 
				
			||||||
 | 
					        key: cmake-${{ matrix.cmake }}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    - name: Install dependencies
 | 
					    - name: Install dependencies
 | 
				
			||||||
      run: apt update && apt install -y python3 python3-pip gcc libgl1-mesa-dev libx11-dev libxext-dev && pip install cmake
 | 
					      shell: bash
 | 
				
			||||||
 | 
					      run: |
 | 
				
			||||||
 | 
					        cmake=${{ matrix.cmake }}
 | 
				
			||||||
 | 
					        apt update
 | 
				
			||||||
 | 
					        apt install -y gcc make libgl1-mesa-dev libx11-dev libxext-dev
 | 
				
			||||||
 | 
					        if [ -x /opt/cmake/bin/cmake ]; then
 | 
				
			||||||
 | 
					          echo "Found cached cmake"
 | 
				
			||||||
 | 
					          if [ -s "$(/opt/cmake/bin/cmake --version | grep ${cmake})" ]; then
 | 
				
			||||||
 | 
					            exit 0
 | 
				
			||||||
 | 
					          fi
 | 
				
			||||||
 | 
					          echo "CMake version is mismatched"
 | 
				
			||||||
 | 
					          rm -rf /opt/cmake
 | 
				
			||||||
 | 
					        fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        apt install -y g++ wget
 | 
				
			||||||
 | 
					        if [ "${cmake}" == "latest" ]; then
 | 
				
			||||||
 | 
					          apt install -y git
 | 
				
			||||||
 | 
					          cmake=$(git ls-remote --tags https://gitlab.kitware.com/cmake/cmake | cut -f 2 | sed -E "s/^refs\/tags\/v//" | tr -d "^{}" | sort -t '.' -k 1,1n -k 2,2n -k 3,3n | tail -n 1 | tr -d "\n")
 | 
				
			||||||
 | 
					          echo "Latest version: ${cmake}"
 | 
				
			||||||
 | 
					        fi
 | 
				
			||||||
 | 
					        short_version=$(echo "${cmake}" | sed -E "s/^([0-9]+\\.[0-9]+)\\..+$/\\1/" | tr -d "\n")
 | 
				
			||||||
 | 
					        wget https://cmake.org/files/v${short_version}/cmake-${cmake}.tar.gz
 | 
				
			||||||
 | 
					        tar -xf cmake-${cmake}.tar.gz
 | 
				
			||||||
 | 
					        cd cmake-${cmake}
 | 
				
			||||||
 | 
					        ./configure --prefix=/opt/cmake
 | 
				
			||||||
 | 
					        make -j $(nproc) install
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    - name: Save cmake
 | 
				
			||||||
 | 
					      uses: actions/cache/save@v4
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        path: /opt/cmake
 | 
				
			||||||
 | 
					        key: cmake-${{ matrix.cmake }}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    - name: Configure CMake
 | 
					    - name: Configure CMake
 | 
				
			||||||
      shell: bash
 | 
					      shell: bash
 | 
				
			||||||
      run: cmake . -DCMAKE_BUILD_TYPE=$BUILD_TYPE
 | 
					      run: /opt/cmake/bin/cmake . -DCMAKE_BUILD_TYPE=$BUILD_TYPE
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    - name: Build test
 | 
					    - name: Build test
 | 
				
			||||||
      shell: bash
 | 
					      shell: bash
 | 
				
			||||||
      run: cmake --build .
 | 
					      run: /opt/cmake/bin/cmake --build .
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    - name: Check alias
 | 
					    - name: Check alias
 | 
				
			||||||
      shell: bash
 | 
					      shell: bash
 | 
				
			||||||
      run: test -e lib/libGLEW.a
 | 
					      run: test -e lib/libGLEW.a
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  build_mingw:
 | 
					  build_mingw:
 | 
				
			||||||
    # The CMake configure and build commands are platform agnostic and should work equally
 | 
					 | 
				
			||||||
    # well on Windows or Mac.  You can convert this to a matrix build if you need
 | 
					 | 
				
			||||||
    # cross-platform coverage.
 | 
					 | 
				
			||||||
    # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
 | 
					 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    container: ubuntu:18.04
 | 
					    container: ubuntu:latest
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
    - uses: actions/checkout@v2
 | 
					    - uses: actions/checkout@v2
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user