File: build_wheels.bat

package info (click to toggle)
plotpy 2.8.2-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 13,364 kB
  • sloc: python: 37,833; cpp: 2,005; sh: 32; makefile: 3
file content (38 lines) | stat: -rw-r--r-- 1,450 bytes parent folder | download | duplicates (2)
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
@echo off
REM This script was copied from PythonQwt project
REM ======================================================
REM Package build script
REM ======================================================
REM Licensed under the terms of the MIT License
REM Copyright (c) 2020 Pierre Raybaut
REM (see PythonQwt LICENSE file for more details)
REM ======================================================
setlocal enabledelayedexpansion
call %~dp0utils GetScriptPath SCRIPTPATH
call %FUNC% GetModName MODNAME
call %FUNC% SetPythonPath

if exist MANIFEST ( del /q MANIFEST )
:: Iterate over all directories in the grandparent directory
:: (WinPython base directories)
call %FUNC% GetPythonExeGrandParentDir DIR0
for /D %%d in ("%DIR0%*") do (
    :: Get the directory name without the path
    for %%n in (%%d) do set "DIRNAME=%%~nxn"

    :: Check if the directory ends with "-PyQt6" or "-PySide6"
    if not "!DIRNAME:~-6!"=="-PyQt6" (
        if not "!DIRNAME:~-8!"=="-PySide6" (
            set WINPYDIRBASE=%%d
            set OLD_PATH=!PATH!
            call !WINPYDIRBASE!\scripts\env.bat
            echo ******************************************************************************
            echo Building %MODNAME% from "%%d"
            echo ******************************************************************************
            python -m build
            echo ----
            set PATH=!OLD_PATH!
        )
    )
)
call %FUNC% EndOfScript