2015-12-08 15:45:58 -07:00
|
|
|
# Copyright (c) 2015 Cisco and/or its affiliates.
|
|
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
# you may not use this file except in compliance with the License.
|
|
|
|
# You may obtain a copy of the License at:
|
|
|
|
#
|
|
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
#
|
|
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
# See the License for the specific language governing permissions and
|
|
|
|
# limitations under the License.
|
|
|
|
|
|
|
|
# Pick up per-platform makefile fragments
|
|
|
|
$(foreach d,$(SOURCE_PATH_BUILD_DATA_DIRS), \
|
|
|
|
$(eval -include $(d)/platforms/*.mk))
|
|
|
|
|
|
|
|
.PHONY: install-deb
|
|
|
|
install-deb: $(patsubst %,%-find-source,$(ROOT_PACKAGES))
|
|
|
|
@$(BUILD_ENV) ; \
|
|
|
|
set -eu$(BUILD_DEBUG) ; \
|
|
|
|
$(MAKE) -C $(MU_BUILD_ROOT_DIR) \
|
|
|
|
$(patsubst %,%-install, \
|
|
|
|
$(ROOT_PACKAGES)) || exit 1; \
|
|
|
|
\
|
|
|
|
: generate file manifests ; \
|
|
|
|
find $(INSTALL_PREFIX)$(ARCH)/*/bin -type f -print \
|
2016-12-28 18:38:59 +01:00
|
|
|
| sed -e 's:.*:../& /usr/bin:' | grep -v vppapigen \
|
2015-12-08 15:45:58 -07:00
|
|
|
> deb/debian/vpp.install ; \
|
2016-02-03 12:59:38 -05:00
|
|
|
\
|
2016-12-01 21:49:03 +01:00
|
|
|
: core api definitions ; \
|
|
|
|
./scripts/find-api-core-contents $(INSTALL_PREFIX)$(ARCH) \
|
|
|
|
deb/debian/vpp.install ; \
|
|
|
|
\
|
2016-02-03 12:59:38 -05:00
|
|
|
: need symbolic links in the lib pkg ; \
|
|
|
|
find $(INSTALL_PREFIX)$(ARCH)/*/lib* \( -type f -o -type l \) \
|
|
|
|
-print | egrep -e '*\.so\.*\.*\.*' \
|
2016-07-13 13:42:33 +02:00
|
|
|
| grep -v plugins\/ \
|
2017-12-27 10:31:41 +00:00
|
|
|
| sed -e 's:.*:../& /usr/lib/$(MACHINE)-linux-gnu:' \
|
2015-12-08 15:45:58 -07:00
|
|
|
> deb/debian/vpp-lib.install ; \
|
|
|
|
\
|
2016-12-01 21:49:03 +01:00
|
|
|
: vnet api definitions ; \
|
|
|
|
./scripts/find-api-lib-contents $(INSTALL_PREFIX)$(ARCH) \
|
|
|
|
deb/debian/vpp-lib.install ; \
|
|
|
|
\
|
2015-12-08 15:45:58 -07:00
|
|
|
: dev package ; \
|
|
|
|
./scripts/find-dev-contents $(INSTALL_PREFIX)$(ARCH) \
|
|
|
|
deb/debian/vpp-dev.install ; \
|
|
|
|
\
|
2016-07-13 13:42:33 +02:00
|
|
|
: plugins package ; \
|
|
|
|
./scripts/find-plugins-contents $(INSTALL_PREFIX)$(ARCH) \
|
|
|
|
deb/debian/vpp-plugins.install ; \
|
|
|
|
\
|
2016-12-28 18:38:59 +01:00
|
|
|
: vpp-api-lua package ; \
|
|
|
|
./scripts/find-vpp-api-lua-contents $(INSTALL_PREFIX)$(ARCH) \
|
|
|
|
deb/debian/vpp-api-lua.install ; \
|
|
|
|
\
|
|
|
|
: vpp-api-java package ; \
|
|
|
|
./scripts/find-vpp-api-java-contents $(INSTALL_PREFIX)$(ARCH) \
|
|
|
|
deb/debian/vpp-api-java.install ; \
|
|
|
|
\
|
2015-12-08 15:45:58 -07:00
|
|
|
: bin package needs startup config ; \
|
2016-12-19 23:05:39 +01:00
|
|
|
echo ../../src/vpp/conf/startup.conf /etc/vpp \
|
2015-12-08 15:45:58 -07:00
|
|
|
>> deb/debian/vpp.install ; \
|
|
|
|
\
|
|
|
|
: and sysctl config ; \
|
2016-12-19 23:05:39 +01:00
|
|
|
echo ../../src/vpp/conf/80-vpp.conf /etc/sysctl.d \
|
2015-12-08 15:45:58 -07:00
|
|
|
>> deb/debian/vpp.install ; \
|
|
|
|
\
|
2017-01-10 17:10:39 +00:00
|
|
|
: bash completion for vppctl ; \
|
|
|
|
echo ../../src/scripts/vppctl_completion /etc/bash_completion.d \
|
|
|
|
>> deb/debian/vpp.install ; \
|
|
|
|
\
|
|
|
|
: move dictionary of vppctl commands ; \
|
|
|
|
echo ../../src/scripts/vppctl-cmd-list /usr/share/vpp \
|
|
|
|
>> deb/debian/vpp.install ; \
|
|
|
|
\
|
2018-01-15 17:54:52 -05:00
|
|
|
: add log directory ; \
|
|
|
|
echo /var/log/vpp/ \
|
|
|
|
>> deb/debian/vpp.dirs ; \
|
|
|
|
\
|
2015-12-08 15:45:58 -07:00
|
|
|
: dev package needs a couple of additions ; \
|
2016-12-28 17:51:56 +01:00
|
|
|
echo ../$(INSTALL_PREFIX)$(ARCH)/vpp/bin/vppapigen /usr/bin \
|
2016-08-01 04:59:13 +02:00
|
|
|
>> deb/debian/vpp-dev.install ; \
|
2017-10-12 13:06:35 +02:00
|
|
|
echo ../$(INSTALL_PREFIX)$(ARCH)/vpp/share/vpp/C.py /usr/share/vpp \
|
|
|
|
>> deb/debian/vpp-dev.install ; \
|
|
|
|
echo ../$(INSTALL_PREFIX)$(ARCH)/vpp/share/vpp/JSON.py /usr/share/vpp \
|
|
|
|
>> deb/debian/vpp-dev.install ; \
|
2016-12-28 18:38:59 +01:00
|
|
|
echo ../../src/vpp-api/java/jvpp/gen/jvpp_gen.py /usr/bin \
|
2016-08-01 04:59:13 +02:00
|
|
|
>> deb/debian/vpp-dev.install ; \
|
2016-12-28 18:38:59 +01:00
|
|
|
for i in $$(ls ../src/vpp-api/java/jvpp/gen/jvppgen/*.py); do \
|
2016-08-01 04:59:13 +02:00
|
|
|
echo ../$${i} /usr/lib/python2.7/dist-packages/jvppgen \
|
|
|
|
>> deb/debian/vpp-dev.install; \
|
|
|
|
done; \
|
2015-12-08 15:45:58 -07:00
|
|
|
\
|
|
|
|
: generate changelog; \
|
|
|
|
./scripts/generate-deb-changelog \
|
|
|
|
\
|
|
|
|
: Go fabricate the actual Debian packages ; \
|
|
|
|
( \
|
|
|
|
cd deb && \
|
|
|
|
dpkg-buildpackage -us -uc -b \
|
|
|
|
)
|
|
|
|
|