Merge pull request #4 from Egor00f/add-installation-path-selection

Add installation path selection
This commit is contained in:
Егор 2024-11-09 22:36:59 +05:00 committed by GitHub
commit f2ee70e825
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
8 changed files with 50 additions and 5 deletions

View File

@ -0,0 +1,19 @@
{
"image": "mcr.microsoft.com/devcontainers/cpp:debian-12",
"features": {
},
"customizations": {
"vscode": {
"extensions": [
"ms-vscode.cmake-tools",
"usernamehw.errorlens",
"streetsidesoftware.code-spell-checker",
"streetsidesoftware.code-spell-checker-russian",
"ibm.output-colorizer",
"chouzz.vscode-innosetup",
"github.vscode-github-actions"
]
}
}
}

View File

@ -16,7 +16,7 @@ jobs:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: Run script - name: Run script
run: ${{ github.workspace }}/./install.sh run: echo '/home/autobuild/tools' | ${{ github.workspace }}/./install.sh
- name: Add toolchain to path - name: Add toolchain to path
run: echo "/home/autobuild/tools/win32/bin" >> $GITHUB_PATH run: echo "/home/autobuild/tools/win32/bin" >> $GITHUB_PATH
@ -60,6 +60,12 @@ jobs:
cmake -B ${{ github.workspace }}/build cmake -B ${{ github.workspace }}/build
cmake --build ${{ github.workspace }}/build --target Installer cmake --build ${{ github.workspace }}/build --target Installer
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
# Upload entire repository
path: './build'
# Test Package # Test Package
package: package:
runs-on: ubuntu-latest runs-on: ubuntu-latest
@ -71,8 +77,14 @@ jobs:
cmake -B ${{ github.workspace }}/build cmake -B ${{ github.workspace }}/build
cmake --build ${{ github.workspace }}/build --target Package cmake --build ${{ github.workspace }}/build --target Package
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
# Upload entire repository
path: './build'
- name: Install package - name: Install package
run: sudo apt install ${{ github.workspace }}/build/package.deb run: echo '/home/autobuild/tools' | sudo apt install ${{ github.workspace }}/build/package.deb -y
- name: Add toolchain to path - name: Add toolchain to path
run: echo "/home/autobuild/tools/win32/bin" >> $GITHUB_PATH run: echo "/home/autobuild/tools/win32/bin" >> $GITHUB_PATH
@ -84,3 +96,4 @@ jobs:
- name: Remove package - name: Remove package
run: sudo apt remove kos32-gcc run: sudo apt remove kos32-gcc

View File

@ -3,6 +3,7 @@
"chouzz.vscode-innosetup", "chouzz.vscode-innosetup",
"streetsidesoftware.code-spell-checker", "streetsidesoftware.code-spell-checker",
"streetsidesoftware.code-spell-checker-russian", "streetsidesoftware.code-spell-checker-russian",
"ms-vscode.cmake-tools" "ms-vscode.cmake-tools",
"github.vscode-github-actions"
] ]
} }

View File

@ -9,6 +9,7 @@ project(
add_custom_target( add_custom_target(
Package Package
COMMAND cp -f ${CMAKE_CURRENT_SOURCE_DIR}/install.sh ${CMAKE_CURRENT_SOURCE_DIR}/package/DEBIAN/postinst COMMAND cp -f ${CMAKE_CURRENT_SOURCE_DIR}/install.sh ${CMAKE_CURRENT_SOURCE_DIR}/package/DEBIAN/postinst
COMMAND chmod 775 ${CMAKE_CURRENT_SOURCE_DIR}/package/DEBIAN/postinst
COMMAND dpkg-deb --build ${CMAKE_CURRENT_SOURCE_DIR}/package ${CMAKE_CURRENT_BINARY_DIR}/package.deb COMMAND dpkg-deb --build ${CMAKE_CURRENT_SOURCE_DIR}/package ${CMAKE_CURRENT_BINARY_DIR}/package.deb
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
) )

View File

@ -30,8 +30,18 @@ check_utils(){
pwd pwd
TOOLCHAIN_DIR="/home/autobuild/tools" TOOLCHAIN_DIR="/home/autobuild/tools"
MESSAGE="Toolchain install path(default is $TOOLCHAIN_DIR): "
echo -n $MESSAGE
read INPUT
if [[ ! -z "$INPUT" ]]; then
TOOLCHAIN_DIR=$INPUT
fi
print_msg "Checking utilities..." print_msg "Checking utilities..."

View File

@ -2,7 +2,7 @@
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
#define MyAppName "KolibriOS gcc toolchain" #define MyAppName "KolibriOS gcc toolchain"
#define MyAppVersion "0.1.3" #define MyAppVersion "0.1.4"
#define MyAppPublisher "Egor00f" #define MyAppPublisher "Egor00f"
#define MyAppURL "https://github.com/Egor00f/kolibrios-gcc-toolchain" #define MyAppURL "https://github.com/Egor00f/kolibrios-gcc-toolchain"

2
package/DEBIAN/control Normal file → Executable file
View File

@ -1,5 +1,5 @@
Package: kos32-gcc Package: kos32-gcc
Version: 0.1.3 Version: 0.1.4
Architecture: all Architecture: all
Section: devel Section: devel
Depends: libc6-i386:amd64, libmpc3:amd64 Depends: libc6-i386:amd64, libmpc3:amd64

1
package/DEBIAN/dirs Normal file
View File

@ -0,0 +1 @@
/home/autobuild/tools/