Use install instead of cp for install purposes. The install utility will set the proper permissions for the file at hand while cp just sets the permissions at the destination it gets from the original file - which might be totally wrong depending on the users' umask. Signed-off-by: Henner Zeller <h.zeller@acm.org>
diff --git a/Makefile_plugin.common b/Makefile_plugin.common index 4289bd6..06f2c61 100644 --- a/Makefile_plugin.common +++ b/Makefile_plugin.common
@@ -48,8 +48,7 @@ $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared -o $@ $^ $(LDLIBS) install_plugin: $(NAME).so - mkdir -p $(PLUGINS_DIR) - cp $< $(PLUGINS_DIR)/$< + install -D $< $(PLUGINS_DIR)/$< test: $(MAKE) -C tests all
diff --git a/xdc-plugin/Makefile b/xdc-plugin/Makefile index bd454a1..0ca7ba3 100644 --- a/xdc-plugin/Makefile +++ b/xdc-plugin/Makefile
@@ -4,7 +4,6 @@ VERILOG_MODULES = BANK.v install_modules: $(VERILOG_MODULES) - mkdir -p $(PLUGINS_DIR)/fasm_extra_modules/ - cp $< $(PLUGINS_DIR)/fasm_extra_modules/$< + install -D $< $(PLUGINS_DIR)/fasm_extra_modules/$< install: install_modules