Currently it is only possible to run the modules for the IoT Box on Raspios. The modifications brought by this commit brings the possibility that the various hw_* modules can be executed whatever the OS of the hardware (Linux or Windows). If the modules should be versioned according to the OS, the file will be renamed so that the end of the file includes *_L (for linux) or *_W (for windows) closes odoo/odoo#107350 X-original-commit: b7b8809ea8b7fe4ac8b24f43fe3f3a5e38a66696 Related: odoo/enterprise#34713 Signed-off-by: Quentin Lejeune (qle) <qle@odoo.com>
46 lines
1.9 KiB
Makefile
46 lines
1.9 KiB
Makefile
include Makefile.version
|
|
include Makefile.python
|
|
include Makefile.servicename
|
|
|
|
SERVER_DIRECTORY=../..
|
|
FILES_DIRECTORY=release
|
|
|
|
MAKENSIS_ARGUMENTS=/DVERSION=$(VERSION) /DMAJOR_VERSION=$(MAJORVERSION) /DMINOR_VERSION=$(MINORVERSION) /DSERVICENAME=${SERVICENAME} /DPYTHONVERSION=${PYTHON_VERSION}
|
|
|
|
LAUNCH_MAKENSIS=/cygdrive/c/tools/cygwin/makensis $(MAKENSIS_ARGUMENTS) setup.nsi
|
|
WINPY32_DIR=/cygdrive/c/odoobuild/WinPy32/python-${PYTHON_VERSION}
|
|
WINPY64_DIR=/cygdrive/c/odoobuild/WinPy64/python-${PYTHON_VERSION}.amd64
|
|
|
|
default: allinone
|
|
|
|
clean: server_clean
|
|
rm -rf $(FILES_DIRECTORY)/*.exe
|
|
rm -rf *.exe
|
|
|
|
server_clean:
|
|
rm -rf $(SERVER_DIRECTORY)/dist
|
|
rm -rf $(SERVER_DIRECTORY)/build
|
|
rm -rf $(SERVER_DIRECTORY)/win32/dist
|
|
rm -rf $(SERVER_DIRECTORY)/win32/build
|
|
rm -rf $(SERVER_DIRECTORY)/*.exe
|
|
rm -rf $(SERVER_DIRECTORY)/.cyg*
|
|
|
|
allinone: server_clean
|
|
# need to install requirements-local-proxy.txt for local proxy install
|
|
cp $(SERVER_DIRECTORY)/requirements.txt $(WINPY32_DIR)/
|
|
cp requirements-local-proxy.txt $(WINPY32_DIR)/
|
|
-(cd $(WINPY32_DIR) && ./python.exe -m pip install --upgrade pip)
|
|
-(cd $(WINPY32_DIR) && cat requirements*.txt | while read PAC ; do Scripts/pip3.exe install "$${PAC%%#*}" ; done)
|
|
-(cd $(WINPY32_DIR) && Scripts/pip3.exe list)
|
|
rm $(WINPY32_DIR)/requirements.txt
|
|
cp $(SERVER_DIRECTORY)/requirements.txt $(WINPY64_DIR)/
|
|
cp requirements-local-proxy.txt $(WINPY64_DIR)/
|
|
-(cd $(WINPY64_DIR) && ./python.exe -m pip install --upgrade pip)
|
|
-(cd $(WINPY64_DIR) && cat requirements*.txt | while read PAC ; do Scripts/pip3.exe install "$${PAC%%#*}" ; done)
|
|
-(cd $(WINPY64_DIR) && Scripts/pip3.exe list)
|
|
rm $(WINPY64_DIR)/requirements.txt
|
|
(cd $(SERVER_DIRECTORY)/setup/win32 && $(LAUNCH_MAKENSIS))
|
|
(cd $(SERVER_DIRECTORY)/setup/win32 && mkdir -p $(FILES_DIRECTORY))
|
|
(cd $(SERVER_DIRECTORY)/setup/win32 && cp odoo_setup_*.exe $(FILES_DIRECTORY)/)
|
|
(cd $(SERVER_DIRECTORY)/setup/win32/$(FILES_DIRECTORY) && chmod 0766 odoo_setup_*.exe)
|