fdo#54087 link the correct resource file to npsoplugin.dll
I had to add a new function to gbuild system: set_nativeres, because the trick in extensions/Library_npsoplugin.mk did not work. It linked the default.res, and that made the plugin unusable under Windows. Also, one export was missing compared to LibreOffice 3.5. Conflicts: extensions/Library_npsoplugin.mk extensions/WinResTarget_npsoplugin.mk Change-Id: Ib91fa2a3b72b15912587f22becccb0aebc2aa390
This commit is contained in:
@@ -78,6 +78,8 @@ $(eval $(call gb_Library_add_defs,npsoplugin,\
|
||||
ifeq ($(COM),MSC)
|
||||
$(eval $(call gb_Library_add_ldflags,npsoplugin,\
|
||||
/EXPORT:NPP_GetMIMEDescription \
|
||||
/EXPORT:NPP_Initialize \
|
||||
/EXPORT:NPP_Shutdown \
|
||||
/EXPORT:NPP_New \
|
||||
/EXPORT:NPP_Destroy \
|
||||
/EXPORT:NPP_SetWindow \
|
||||
@@ -88,7 +90,6 @@ $(eval $(call gb_Library_add_ldflags,npsoplugin,\
|
||||
/EXPORT:NPP_StreamAsFile \
|
||||
/EXPORT:NPP_URLNotify \
|
||||
/EXPORT:NPP_Print \
|
||||
/EXPORT:NPP_Shutdown \
|
||||
/EXPORT:NP_GetEntryPoints \
|
||||
/EXPORT:NP_Initialize \
|
||||
/EXPORT:NP_Shutdown \
|
||||
@@ -96,11 +97,7 @@ $(eval $(call gb_Library_add_ldflags,npsoplugin,\
|
||||
))
|
||||
endif
|
||||
|
||||
# Trick to get rid of the default.res to avoid duplicate VERSION
|
||||
# resource: Set NATIVERES for npsoplugin to be *only* nsplugin_oo
|
||||
|
||||
$(eval $(call gb_LinkTarget_get_target,npsoplugin) : $(call gb_WinResTarget_get_target,nsplugin_oo))
|
||||
$(eval $(call gb_LinkTarget_get_target,npsoplugin) : NATIVERES := $(call gb_WinResTarget_get_target,nsplugin_oo))
|
||||
$(eval $(call gb_Library_set_nativeres,npsoplugin,npsoplugin/npsoplugin))
|
||||
|
||||
endif # GUI=WNT
|
||||
|
||||
|
@@ -9,8 +9,8 @@
|
||||
#
|
||||
#
|
||||
|
||||
$(eval $(call gb_WinResTarget_WinResTarget,nsplugin_oo))
|
||||
$(eval $(call gb_WinResTarget_WinResTarget,npsoplugin/npsoplugin))
|
||||
|
||||
$(eval $(call gb_WinResTarget_set_rcfile,nsplugin_oo,extensions/source/nsplugin/source/nsplugin_oo))
|
||||
$(eval $(call gb_WinResTarget_set_rcfile,npsoplugin/npsoplugin,extensions/source/nsplugin/source/nsplugin_oo))
|
||||
|
||||
# vim:set noet sw=4 ts=4:
|
||||
|
@@ -265,6 +265,7 @@ $(eval $(foreach method,\
|
||||
add_precompiled_header \
|
||||
export_objects_list \
|
||||
add_nativeres \
|
||||
set_nativeres \
|
||||
set_visibility_default \
|
||||
set_warnings_not_errors \
|
||||
set_generated_cxx_suffix \
|
||||
|
@@ -286,6 +286,12 @@ $(call gb_LinkTarget_get_target,$(1)) : NATIVERES += $(call gb_WinResTarget_get_
|
||||
|
||||
endef
|
||||
|
||||
define gb_LinkTarget_set_nativeres
|
||||
$(call gb_LinkTarget_get_target,$(1)) : $(call gb_WinResTarget_get_target,$(2))
|
||||
$(call gb_LinkTarget_get_target,$(1)) : NATIVERES := $(call gb_WinResTarget_get_target,$(2))
|
||||
|
||||
endef
|
||||
|
||||
define gb_Library_get_dllname
|
||||
$(patsubst $(1):%,%,$(filter $(1):%,$(gb_Library_DLLFILENAMES)))
|
||||
endef
|
||||
|
@@ -357,6 +357,12 @@ $(call gb_LinkTarget_get_target,$(1)) : NATIVERES += $(call gb_WinResTarget_get_
|
||||
|
||||
endef
|
||||
|
||||
define gb_LinkTarget_set_nativeres
|
||||
$(call gb_LinkTarget_get_target,$(1)) : $(call gb_WinResTarget_get_target,$(2))
|
||||
$(call gb_LinkTarget_get_target,$(1)) : NATIVERES := $(call gb_WinResTarget_get_target,$(2))
|
||||
|
||||
endef
|
||||
|
||||
define gb_Library_get_dllname
|
||||
$(patsubst $(1):%,%,$(filter $(1):%,$(gb_Library_DLLFILENAMES)))
|
||||
endef
|
||||
|
Reference in New Issue
Block a user