This commit is contained in:
Peter Li 2025-04-09 21:45:22 -07:00
parent ba73ad5b1c
commit 6279935c7a
4 changed files with 13 additions and 4 deletions

View File

@ -5,11 +5,20 @@
import os import os
import subprocess import subprocess
origDir = os.path.abspath(os.path.dirname(__file__)) from sys import platform
shadercrossDir = os.path.join(origDir, 'shadercross')
shadercross = os.path.join(shadercrossDir, 'bin/shadercross')
origDir = os.path.abspath(os.path.dirname(__file__))
contentDir = os.path.join(origDir, 'content/') contentDir = os.path.join(origDir, 'content/')
shadercrossDir = os.path.join(origDir, 'shadercross/bin')
if platform == "linux" or platform == "linux2":
shadercrossDir = os.path.join(shadercrossDir, 'linux')
elif platform == "darwin":
shadercrossDir = os.path.join(shadercrossDir, 'osx')
elif platform == "win32":
shadercrossDir = os.path.join(shadercrossDir, 'win64')
shadercross = os.path.join(shadercrossDir, 'shadercross')
inputFiles = [os.path.abspath(os.path.join(contentDir, x)) for x in os.listdir(contentDir) if x.endswith('.hlsl')] inputFiles = [os.path.abspath(os.path.join(contentDir, x)) for x in os.listdir(contentDir) if x.endswith('.hlsl')]

View File

@ -31,7 +31,7 @@ os.makedirs(WORKING_DIR, exist_ok=True)
BIN_INSTALL_DIR = os.path.join(origDir, 'bin') BIN_INSTALL_DIR = os.path.join(origDir, 'bin')
from sys import platform from sys import platform
if platform == "linux" or platform == "linux2": if platform == "linux" or platform == "linux2":
BIN_INSTALL_DIR = os.path.join(BIN_INSTALL_DIR, 'linux') BIN_INSTALL_DIR = os.path.join(BIN_INSTALL_DIR, 'linux')
elif platform == "darwin": elif platform == "darwin":