mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
Better handling of RPM architecture variable
This commit is contained in:
parent
f7bc9ecc33
commit
78f352f245
@ -4672,7 +4672,7 @@ def MakeInstallerLinux():
|
|||||||
import compileall
|
import compileall
|
||||||
PYTHONV=os.path.basename(PYTHONSDK)
|
PYTHONV=os.path.basename(PYTHONSDK)
|
||||||
if (os.path.isdir("linuxroot")): oscmd("chmod -R 755 linuxroot")
|
if (os.path.isdir("linuxroot")): oscmd("chmod -R 755 linuxroot")
|
||||||
oscmd("rm -rf linuxroot data.tar.gz control.tar.gz i386 panda3d.spec")
|
oscmd("rm -rf linuxroot data.tar.gz control.tar.gz rpmarch.txt panda3d.spec")
|
||||||
oscmd("mkdir -p linuxroot/usr/bin")
|
oscmd("mkdir -p linuxroot/usr/bin")
|
||||||
oscmd("mkdir -p linuxroot/usr/include")
|
oscmd("mkdir -p linuxroot/usr/include")
|
||||||
oscmd("mkdir -p linuxroot/usr/share/panda3d")
|
oscmd("mkdir -p linuxroot/usr/share/panda3d")
|
||||||
@ -4716,13 +4716,18 @@ def MakeInstallerLinux():
|
|||||||
oscmd("chmod -R 755 linuxroot")
|
oscmd("chmod -R 755 linuxroot")
|
||||||
|
|
||||||
if (os.path.exists("/usr/bin/rpmbuild")):
|
if (os.path.exists("/usr/bin/rpmbuild")):
|
||||||
|
oscmd("rpm -E '{%_arch}' > rpmarch.txt")
|
||||||
|
arch=ReadFile("rpmarch.txt")
|
||||||
|
oscmd("rm -rf "+arch)
|
||||||
txt = INSTALLER_SPEC_FILE[1:].replace("VERSION",VERSION).replace("PANDASOURCE",PANDASOURCE)
|
txt = INSTALLER_SPEC_FILE[1:].replace("VERSION",VERSION).replace("PANDASOURCE",PANDASOURCE)
|
||||||
WriteFile("panda3d.spec", txt)
|
WriteFile("panda3d.spec", txt)
|
||||||
oscmd("rpmbuild --define '_rpmdir "+PANDASOURCE+"' -bb panda3d.spec")
|
oscmd("rpmbuild --define '_rpmdir "+PANDASOURCE+"' -bb panda3d.spec")
|
||||||
oscmd("mv i386/panda3d-"+VERSION+"-1.i386.rpm .")
|
if (os.path.exists(arch+"/panda3d-"+VERSION+"-1."+arch+".rpm")):
|
||||||
|
oscmd("mv "+arch+"/panda3d-"+VERSION+"-1."+arch+".rpm .")
|
||||||
|
oscmd("rm -rf rpmarch.txt "+arch)
|
||||||
|
|
||||||
oscmd("chmod -R 755 linuxroot")
|
oscmd("chmod -R 755 linuxroot")
|
||||||
oscmd("rm -rf linuxroot data.tar.gz control.tar.gz i386 panda3d.spec")
|
oscmd("rm -rf linuxroot data.tar.gz control.tar.gz panda3d.spec")
|
||||||
|
|
||||||
|
|
||||||
if (INSTALLER != 0):
|
if (INSTALLER != 0):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user