fixed install

This commit is contained in:
2025-06-01 15:33:00 -04:00
parent 3776946155
commit 178bd616f5
41 changed files with 21 additions and 18 deletions

View File

@ -14,7 +14,7 @@ depdir = "./dependencies/linux64" #local pre-compiled dependency libraries and t
installdir = "../../linux64" #directory to install to when finished
builddir = "./build_linux64"
doinstall = False #copies the build_output to the install dir when finished
doinstall = True #copies the build_output to the install dir when finished
cc = "g++" #compiler
cflags = "-O3 -fPIC"
libraries = "-l{}".format(libname)
@ -48,10 +48,11 @@ objlist = flist(kwargs['objstore'],exts='.o',recurse=True)
ar_list(objlist,'{}/lib{}.a'.format(builddir,libname))
if(doinstall):
#Copy a binary to the common bin folder
#Push any libraries to the common lib folder
shutil.copy('{}/lib/lib{}.a'.format(builddir,libname),commondir)
shutil.copy(
'{}/lib{}.a'.format(builddir,libname),
"{}/lib".format(installdir)
)
#Copy include files to the common include folder
copytree('./include/',commondir+'/include/',dirs_exist_ok=True)
copytree('./include/',installdir+'/include/',dirs_exist_ok=True)

View File

@ -14,9 +14,9 @@ depdir = "./dependencies/winx64" #local pre-compiled dependency libraries and th
installdir = "../../winx64" #directory to install to when finished
builddir = "./build_mingw64"
doinstall = False #copies the build_output to the install dir when finished
doinstall = True #copies the build_output to the install dir when finished
cc = "x86_64-w64-mingw32-g++" #compiler
cflags = "-fPIC -O3"
cflags = "-fPIC -O3 -std=c++17"
libraries = "-l{}".format(libname)
libdirs = "-L{} -L{}/lib -L{}/lib".format(builddir,commondir,depdir)
linkerflags = "-static -static-libgcc -Wl,-rpath=."
@ -49,10 +49,11 @@ objlist = flist(kwargs['objstore'],exts='.o',recurse=True)
ar_list(objlist,'{}/lib{}.a'.format(builddir,libname))
if(doinstall):
#Copy a binary to the common bin folder
#Push any libraries to the common lib folder
shutil.copy('{}/lib/lib{}.a'.format(builddir,libname),commondir)
shutil.copy(
'{}/lib{}.a'.format(builddir,libname),
"{}/lib".format(installdir)
)
#Copy include files to the common include folder
copytree('./include/',commondir+'/include/',dirs_exist_ok=True)
copytree('./include/',installdir+'/include/',dirs_exist_ok=True)

View File

@ -8,7 +8,7 @@ from shutil import copytree
from amsbuildlib4 import *
libname = "amsmathutil25.mingw64" #static library name to generate
binname = "tests" #create this executable when compiling main.c or main.cpp
binname = "tests.exe" #create this executable when compiling main.c or main.cpp
commondir = "../../winx64" #common directory to pul libraries and includes from
depdir = "./dependencies/winx64" #local pre-compiled dependency libraries and their includes
installdir = "../../winx64" #directory to install to when finished
@ -16,7 +16,7 @@ builddir = "./build_mingw64"
doinstall = False #copies the build_output to the install dir when finished
cc = "x86_64-w64-mingw32-g++" #compiler
cflags = "-fPIC -O3"
cflags = "-fPIC -O3 -std=c++17"
libraries = "-l{}".format(libname)
libdirs = "-L{} -L{}/lib -L{}/lib".format(builddir,commondir,depdir)
linkerflags = "-static -static-libgcc -Wl,-rpath=."

View File

@ -51,10 +51,11 @@ objlist = flist(kwargs['objstore'],exts='.obj',recurse=True)
msvc_lib_list(objlist,'{}/lib{}.lib'.format(builddir,libname))
if(doinstall):
#Copy a binary to the common bin folder
#Push any libraries to the common lib folder
shutil.copy('{}/lib/lib{}.lib'.format(builddir,libname),commondir)
shutil.copy(
'{}/lib{}.lib'.format(builddir,libname),
"{}/lib".format(installdir)
)
#Copy include files to the common include folder
copytree('./include/',commondir+'/include/',dirs_exist_ok=True)
copytree('./include/',installdir+'/include/',dirs_exist_ok=True)

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
build_mingw64/tests.exe Normal file

Binary file not shown.

View File

@ -20,7 +20,7 @@ for o in obj_list:
if(sys.platform!="win32"):
os.chdir('./build_mingw64')
callproc('wine ./tests.exe')
callproc('wine tests.exe')
os.chdir('..')
else:
os.chdir('./build_mingw64')