Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build lib Files on Windows #6740

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
53 commits
Select commit Hold shift + click to select a range
c56080a
build CppController.lib
CoolSpy3 Dec 21, 2024
f4b2af3
generate def files on Windows
CoolSpy3 Dec 21, 2024
0ccd156
generate CppController.def
CoolSpy3 Dec 21, 2024
cc5deb3
mark CppController.def as a target
CoolSpy3 Dec 22, 2024
14eb221
generate def files with dlltool
CoolSpy3 Dec 22, 2024
092c4ad
generate def files in Makefile.include
CoolSpy3 Dec 22, 2024
46bf821
ignore def files
CoolSpy3 Dec 22, 2024
41348c8
clean defs
CoolSpy3 Dec 22, 2024
1306bc6
move linker flags to ldflags
CoolSpy3 Dec 22, 2024
ba85cf4
generate impl libs for all shared libraries
CoolSpy3 Dec 22, 2024
b63b3c6
clean lib files
CoolSpy3 Dec 22, 2024
0f484fc
move implib declaration
CoolSpy3 Dec 22, 2024
c02c381
fix CppController.def target name
CoolSpy3 Dec 22, 2024
74cba18
fix implib extension
CoolSpy3 Dec 22, 2024
07f49cd
copy changes to apply to all targets
CoolSpy3 Dec 22, 2024
80f57f9
add more files to clean
CoolSpy3 Dec 22, 2024
afd08f2
restructuring
CoolSpy3 Dec 22, 2024
20c4947
generate archive files in the correct location
CoolSpy3 Dec 22, 2024
7042bbf
place def files in build directory
CoolSpy3 Dec 22, 2024
d1974e0
actually put def files in the build directory
CoolSpy3 Dec 22, 2024
404354e
match naming conventions of mingw libraries
CoolSpy3 Dec 22, 2024
f1def5a
remove .dll from mingw lib names
CoolSpy3 Dec 22, 2024
4ccffd1
Merge branch 'master' of https://github.com/cyberbotics/webots into b…
CoolSpy3 Dec 22, 2024
4558c0f
update matlab source test to work with new def file
CoolSpy3 Dec 23, 2024
d05f127
reclassify wb_file_get_extension
CoolSpy3 Dec 23, 2024
e757b55
formatting
CoolSpy3 Dec 23, 2024
9fcee27
reclassify wb_node_get_name
CoolSpy3 Dec 23, 2024
9fda13f
add some more ignored Matlab functions
CoolSpy3 Dec 23, 2024
70bab8e
more Matlab functions and restructuring
CoolSpy3 Dec 23, 2024
22e29bb
formatting
CoolSpy3 Dec 23, 2024
a5c076e
make the matlab test work on linux and run it with the main test suite
CoolSpy3 Dec 23, 2024
83a0ec0
formatting
CoolSpy3 Dec 23, 2024
b22c373
wait for WEBOTS_HOME to be defined
CoolSpy3 Dec 23, 2024
ee33197
move import statement
CoolSpy3 Dec 23, 2024
900eca7
write to correct file
CoolSpy3 Dec 23, 2024
3a99e2e
correctly trim metadata
CoolSpy3 Dec 23, 2024
a18d6d4
Revert "make the matlab test work on linux and run it with the main t…
CoolSpy3 Dec 25, 2024
c855662
fix comments
CoolSpy3 Dec 25, 2024
b7c417e
correct revert test suite changes
CoolSpy3 Dec 25, 2024
3f1b77f
generate matlab expected function list from header files
CoolSpy3 Dec 25, 2024
3dad560
Merge branch 'master' of https://github.com/cyberbotics/webots into b…
CoolSpy3 Dec 25, 2024
fbedcb2
remove debug print
CoolSpy3 Dec 25, 2024
87d3f91
use safer shell syntax
CoolSpy3 Dec 25, 2024
77d6f95
formatting
CoolSpy3 Dec 25, 2024
6fb1a25
update matlab function exclusions
CoolSpy3 Dec 25, 2024
f5011d9
remove unused check
CoolSpy3 Dec 25, 2024
282c49d
detect constants
CoolSpy3 Dec 25, 2024
e5bc091
formatting
CoolSpy3 Dec 25, 2024
249375e
debugging info
CoolSpy3 Dec 25, 2024
9aec7d6
write to stderr
CoolSpy3 Dec 25, 2024
1848ba8
more info
CoolSpy3 Dec 25, 2024
cb8f73a
correctly parse globs
CoolSpy3 Dec 25, 2024
fe292a8
use subprocess directly
CoolSpy3 Dec 25, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ webots_catkin_ws
*.hex
*.pyc
*.gch
*.def

# Packages
*.7z
Expand Down
4 changes: 2 additions & 2 deletions include/controller/c/webots/supervisor.h
Original file line number Diff line number Diff line change
Expand Up @@ -215,10 +215,10 @@ void wb_supervisor_simulation_revert() WB_DEPRECATED; // please us
void wb_supervisor_load_world(const char *filename) WB_DEPRECATED; // please use wb_supervisor_world_load() instead
bool wb_supervisor_save_world(const char *filename) WB_DEPRECATED; // please use wb_supervisor_world_save() instead

// deprecated since Webots 8.6.0, plesae use wb_supervisor_field_remove_mf_item() instead
// deprecated since Webots 8.6.0, please use wb_supervisor_field_remove_mf() instead
void wb_supervisor_field_remove_mf_node(WbFieldRef field, int position) WB_DEPRECATED;

// deprecated since Webots 8.0.0, plesae use wb_supervisor_simulation_reset_physics() instead
// deprecated since Webots 8.0.0, pleaae use wb_supervisor_simulation_reset_physics() instead
void wb_supervisor_simulation_physics_reset() WB_DEPRECATED;

// deprecated since Webots 8.4.0 please use wb_supervisor_movie_is_ready and wb_supervisor_movie_failed
Expand Down
28 changes: 0 additions & 28 deletions projects/default/libraries/vehicle/c/car/car.def

This file was deleted.

30 changes: 0 additions & 30 deletions projects/default/libraries/vehicle/c/driver/driver.def

This file was deleted.

This file was deleted.

46 changes: 24 additions & 22 deletions resources/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -395,10 +395,9 @@ endif
ifeq ($(OSTYPE),windows)
ifdef BUILD_SHARED_LIBRARY
ifndef USE_CXX
ifneq ($(wildcard /C/Program\ Files\ */Microsoft\ Visual\ Studio/2017),)
VISUAL_STUDIO_PATH?=/C/Program Files (x86)/Microsoft Visual Studio/2017
endif
VS_DEF_NAME = $(NAME).def
ifneq ($(wildcard /C/Program\ Files\ */Microsoft\ Visual\ Studio/2017),)
VISUAL_STUDIO_PATH?=/C/Program Files (x86)/Microsoft Visual Studio/2017
endif
endif
endif
endif
Expand Down Expand Up @@ -478,15 +477,22 @@ clean: $(EXTRA_TARGETS)
ifdef MAIN_TARGET

MAIN_TARGET_WINDOWS_LIB = $(MAIN_TARGET:.dll=.lib)
MAIN_TARGET_MINGW_LIB_NAME = lib$(MAIN_TARGET:.dll=.a)
ifdef WEBOTS_LIBRARY
MAIN_TARGET_COPY = "$(subst $(space),\ ,$(WEBOTS_CONTROLLER_LIB_PATH))/$(MAIN_TARGET)"
MAIN_TARGET_WINDOWS64_LIB = $(WEBOTS_CONTROLLER_LIB_PATH)/$(MAIN_TARGET_WINDOWS_LIB)
MAIN_TARGET_MINGW_LIB = $(WEBOTS_CONTROLLER_LIB_PATH)/$(MAIN_TARGET_MINGW_LIB_NAME)
else
MAIN_TARGET_COPY ?= $(MAIN_TARGET)
MAIN_TARGET_WINDOWS64_LIB = $(MAIN_TARGET:.dll=.lib)
MAIN_TARGET_MINGW_LIB = $(MAIN_TARGET_MINGW_LIB_NAME)
endif
ifeq ($(OSTYPE),windows)
FILES_TO_REMOVE += $(MAIN_TARGET_WINDOWS64_LIB)
ifdef BUILD_SHARED_LIBRARY
VS_DEF_NAME = $(BUILD_GOAL_DIR)/$(MAIN_TARGET:.dll=.def)
DYNAMIC_LINK_FLAGS += -Wl,--out-implib,$(MAIN_TARGET_MINGW_LIB)
endif
endif

###-----------------------------------------------------------------------------
Expand All @@ -508,15 +514,13 @@ ifdef TARGET_LIB_DIR
$(MAIN_TARGET): $(TARGET_LIB_DIR)/$(MAIN_TARGET)
ifdef VS_DEF_NAME
@# Generate the .lib libraries to facilitate the integration with Visual Studio
@# if the .def file is existing.
@if [ -f $(VS_DEF_NAME) ]; then \
if [ -d "$(VISUAL_STUDIO_PATH)" ]; then \
PATH="$(VISUAL_STUDIO_PATH)/BuildTools/VC/Tools/MSVC/14.16.27023/bin/Hostx64/x64":$PATH lib /machine:X64 /def:$(VS_DEF_NAME) /out:out.lib > /dev/null; \
mv out.lib $(MAIN_TARGET_WINDOWS64_LIB); \
rm -f *.exp; \
else \
$(ECHO) "\033[0;33m'VISUAL_STUDIO_PATH' environmental variable not set or Microsoft Visual Studio not installed, skipping $(NAME).lib\033[0m"; \
fi \
@dlltool --export-all-symbols -z $(VS_DEF_NAME) $(TARGET_LIB_DIR)/$(MAIN_TARGET)
@if [ -d "$(VISUAL_STUDIO_PATH)" ]; then \
PATH="$(VISUAL_STUDIO_PATH)/BuildTools/VC/Tools/MSVC/14.16.27023/bin/Hostx64/x64":$PATH lib /machine:X64 /def:$(VS_DEF_NAME) /out:out.lib > /dev/null; \
mv out.lib $(MAIN_TARGET_WINDOWS64_LIB); \
rm -f *.exp; \
else \
$(ECHO) "\033[0;33m'VISUAL_STUDIO_PATH' environmental variable not set or Microsoft Visual Studio not installed, skipping $(NAME).lib\033[0m"; \
fi
endif

Expand All @@ -530,15 +534,13 @@ $(MAIN_TARGET): $(BUILD_GOAL_DIR)/$(MAIN_TARGET)
@rm -f $(MAIN_TARGET) > /dev/null 2>&1 && echo "# copying to" $(MAIN_TARGET_COPY) && cp $(BUILD_GOAL_DIR)/$(MAIN_TARGET) $(MAIN_TARGET_COPY) > /dev/null 2>&1
ifdef VS_DEF_NAME
@# Generate the .lib libraries to facilitate the integration with Visual Studio
@# if the .def file is existing.
@if [ -f $(VS_DEF_NAME) ]; then \
if [ -d "$(VISUAL_STUDIO_PATH)" ]; then \
PATH="$(VISUAL_STUDIO_PATH)/BuildTools/VC/Tools/MSVC/14.16.27023/bin/Hostx64/x64":$PATH lib /machine:X64 /def:$(VS_DEF_NAME) /out:out.lib > /dev/null; \
mv out.lib $(MAIN_TARGET_WINDOWS64_LIB); \
rm -f *.exp; \
else \
$(ECHO) "\033[0;33m'VISUAL_STUDIO_PATH' environmental variable not set or Microsoft Visual Studio not installed, skipping $(NAME).lib\033[0m"; \
fi \
@dlltool --export-all-symbols -z $(VS_DEF_NAME) $(BUILD_GOAL_DIR)/$(MAIN_TARGET)
@if [ -d "$(VISUAL_STUDIO_PATH)" ]; then \
PATH="$(VISUAL_STUDIO_PATH)/BuildTools/VC/Tools/MSVC/14.16.27023/bin/Hostx64/x64":$PATH lib /machine:X64 /def:$(VS_DEF_NAME) /out:out.lib > /dev/null; \
mv out.lib $(MAIN_TARGET_WINDOWS64_LIB); \
rm -f *.exp; \
else \
$(ECHO) "\033[0;33m'VISUAL_STUDIO_PATH' environmental variable not set or Microsoft Visual Studio not installed, skipping $(NAME).lib\033[0m"; \
fi
endif

Expand Down
Loading
Loading