Skip to content

Commit

Permalink
Include only Ice and IceMX modules with Python package (#2463)
Browse files Browse the repository at this point in the history
  • Loading branch information
pepone authored Jul 11, 2024
1 parent d8f7575 commit f6591df
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 46 deletions.
15 changes: 6 additions & 9 deletions python/msbuild/ice.proj
Original file line number Diff line number Diff line change
Expand Up @@ -32,17 +32,14 @@
</ItemDefinitionGroup>

<ItemGroup>
<SliceCompile Include="..\..\slice\Ice\*.ice;
..\..\slice\Glacier2\*.ice"
Exclude="..\..\slice\Ice\Metrics.ice;
..\..\slice\Glacier2\Metrics.ice">
<SliceCompile Include="..\..\slice\Ice\*.ice"
Exclude="..\..\slice\Ice\Metrics.ice">
<AdditionalOptions>--no-package %(AdditionalOptions)</AdditionalOptions>
</SliceCompile>
<SliceCompile Include="..\..\slice\Glacier2\Metrics.ice;
..\..\slice\Ice\Metrics.ice;
..\..\slice\IceBox\*.ice;
..\..\slice\IceGrid\*.ice;
..\..\slice\IceStorm\*.ice"/>
<!-- Generate this file individually without the "no-package" option to ensure the
IceMX package is updated. -->
<SliceCompile Include="..\..\slice\Ice\Metrics.ice">
</SliceCompile>
<PythonGenerated Include="$(MSBuildThisFileDirectory)\..\python\**\*_ice.py"/>
</ItemGroup>

Expand Down
22 changes: 0 additions & 22 deletions python/python/Glacier2/__init__.py

This file was deleted.

14 changes: 3 additions & 11 deletions python/python/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,12 @@ $(eval $(call load-translator-dependencies,$(top_srcdir)/cpp/src/slice2py))
.NOTPARALLEL:

$(eval $(call make-python-package,$(slicedir),$(lang_srcdir)/python,Ice,--no-package))
$(eval $(call make-python-package,$(slicedir),$(lang_srcdir)/python,Glacier2,--no-package))
$(eval $(call make-python-package,$(slicedir),$(lang_srcdir)/python,IceBox))
$(eval $(call make-python-package,$(slicedir),$(lang_srcdir)/python,IceMX))
$(eval $(call make-python-package,$(slicedir),$(lang_srcdir)/python,IceGrid))
$(eval $(call make-python-package,$(slicedir),$(lang_srcdir)/python,IceStorm))

# Generate these two files individually without the --no-package option to ensure the
# Generate this file individually without the --no-package option to ensure the
# IceMX package is updated.
$(eval $(call make-python-slice,$(slicedir),$(lang_srcdir)/python,Ice,Metrics))
$(eval $(call make-python-slice,$(slicedir),$(lang_srcdir)/python,Glacier2,Metrics))

install:: | $(DESTDIR)$(install_pythondir)/Ice
$(E) "Installing generated code"
$(Q)$(INSTALL) -m 644 Ice/__init__.py $(DESTDIR)$(install_pythondir)/Ice

install:: | $(DESTDIR)$(install_pythondir)/Glacier2
$(Q)$(INSTALL) -m 644 Glacier2/__init__.py $(DESTDIR)$(install_pythondir)/Glacier2
$(E) "Installing python code"
$(Q)$(INSTALL) -m 644 Ice/*.py $(DESTDIR)$(install_pythondir)/Ice
4 changes: 0 additions & 4 deletions python/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,8 @@

# Define Python packages to be included
packages = [
'Glacier2',
'Ice',
'IceBox',
'IceGrid',
'IceMX',
'IceStorm',
'slice',
'slice.Glacier2',
'slice.Ice',
Expand Down
1 change: 1 addition & 0 deletions python/test/Glacier2/router/Client.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

from TestHelper import TestHelper

TestHelper.loadSlice(f"--all {Ice.getSliceDir()}/Glacier2/Router.ice")
TestHelper.loadSlice("Callback.ice")
import Test

Expand Down

0 comments on commit f6591df

Please sign in to comment.