-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathbuild_cmake.sh
More file actions
executable file
·53 lines (44 loc) · 1.33 KB
/
build_cmake.sh
File metadata and controls
executable file
·53 lines (44 loc) · 1.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#!/bin/bash
# Copyright (C) 2024-2026 Intel Corporation
# SPDX-License-Identifier: MIT
# Build script for Linux using CMake
set -e
BUILD_DIR="build"
BUILD_TYPE="${1:-Release}"
echo "=================================================="
echo "Building vsyncalter with CMake (Linux)"
echo "=================================================="
echo "Build type: $BUILD_TYPE"
echo ""
# Create build directory
if [ -d "$BUILD_DIR" ]; then
echo "Cleaning existing build directory..."
rm -rf "$BUILD_DIR"
fi
mkdir -p "$BUILD_DIR"
cd "$BUILD_DIR"
# Configure
echo "Configuring..."
cmake .. \
-DCMAKE_BUILD_TYPE="$BUILD_TYPE" \
-DBUILD_SHARED_LIBS=ON \
-DBUILD_SWGENLOCK=ON \
-DBUILD_PLLCTL=ON \
-DBUILD_VBLMON=ON \
-DBUILD_FRAMESYNC=ON
# Build
echo "Building..."
cmake --build . -- -j$(nproc)
echo ""
echo "=================================================="
echo "Build complete!"
echo "=================================================="
echo "Binaries location:"
echo " - Library: $BUILD_DIR/lib/"
echo " - pllctl: $BUILD_DIR/pllctl/pllctl"
echo " - vblmon: $BUILD_DIR/vblmon/vblmon"
echo " - swgenlock: $BUILD_DIR/swgenlock/swgenlock"
echo " - framesync: $BUILD_DIR/framesync/framesync"
echo ""
echo "To install: cd $BUILD_DIR && sudo make install"
echo "=================================================="