debian directory for building debian-style package

This commit is contained in:
Seth Alves 2019-05-15 07:25:46 -07:00
parent 5fbb788492
commit edaede0412
11 changed files with 155 additions and 0 deletions

5
debian/changelog vendored Normal file
View file

@ -0,0 +1,5 @@
hifi-interface (84-1) unstable; urgency=medium
* Initial release
-- Seth Alves <seth.alves@gmail.com> Tue, 14 May 2019 19:45:31 -0700

1
debian/compat vendored Normal file
View file

@ -0,0 +1 @@
11

15
debian/control vendored Normal file
View file

@ -0,0 +1,15 @@
Source: hifi-interface
Section: comm
Priority: optional
Maintainer: Seth Alves <seth.alves@gmail.com>
Build-Depends: debhelper (>= 11), cmake
Standards-Version: 4.1.3
Homepage: https://www.highfidelity.com/
Vcs-Browser: https://github.com/highfidelity/hifi
Vcs-Git: https://github.com/highfidelity/hifi.git
Package: hifi-interface
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, libqt5quick5, libqt5quickcontrols2-5, libqt5quickwidgets5, qml-module-qtquick-controls, qml-module-qtquick-controls2, qml-module-qtquick-dialogs, libqt5webchannel5, qml-module-qtwebchannel, qml-module-qtwebengine, qml-module-qt-labs-folderlistmodel, qml-module-qt-labs-settings
Description: High Fidelity allows creation and sharing of VR experiences.
The High Fidelity metaverse provides built-in social features, including avatar interactions, spatialized audio and interactive physics. Additionally, you have the ability to import any 3D object into your virtual environment.

23
debian/copyright vendored Normal file
View file

@ -0,0 +1,23 @@
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Name: hifi-interface
Source: https://github.com/highfidelity/hifi
Files: *
Copyright: 2013-2019, High Fidelity, Inc.
License: Apache-2.0
License: Apache-2.0
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
.
https://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.
.
On Debian systems, the complete text of the Apache version 2.0 license
can be found in "/usr/share/common-licenses/Apache-2.0".

2
debian/hifi-interface-docs.docs vendored Normal file
View file

@ -0,0 +1,2 @@
README.Debian
README.source

1
debian/hifi-interface.dirs vendored Normal file
View file

@ -0,0 +1 @@
opt/hifi/interface/

76
debian/patches/hifi_use_system_qt.diff vendored Normal file
View file

@ -0,0 +1,76 @@
Index: hifi-interface-84/cmake/macros/SetupQt.cmake
===================================================================
--- hifi-interface-84.orig/cmake/macros/SetupQt.cmake
+++ hifi-interface-84/cmake/macros/SetupQt.cmake
@@ -18,19 +18,19 @@ function(calculate_default_qt_dir _QT_VE
elseif(WIN32)
set(QT_DEFAULT_ARCH "msvc2017_64")
else()
- set(QT_DEFAULT_ARCH "gcc_64")
+ set(QT_DEFAULT_ARCH "x86_64-linux-gnu")
endif()
if (WIN32 OR (ANDROID AND ("${CMAKE_HOST_SYSTEM_NAME}" STREQUAL "Windows")))
set(QT_DEFAULT_ROOT "c:/Qt")
else()
- set(QT_DEFAULT_ROOT "$ENV{HOME}/Qt")
+ set(QT_DEFAULT_ROOT "/usr/lib")
endif()
set_from_env(QT_ROOT QT_ROOT ${QT_DEFAULT_ROOT})
set_from_env(QT_ARCH QT_ARCH ${QT_DEFAULT_ARCH})
- set(${_RESULT_NAME} "${QT_ROOT}/${_QT_VERSION}/${QT_ARCH}" PARENT_SCOPE)
+ set(${_RESULT_NAME} "${QT_ROOT}/${QT_ARCH}" PARENT_SCOPE)
endfunction()
# Sets the QT_CMAKE_PREFIX_PATH and QT_DIR variables
@@ -44,7 +44,7 @@ macro(setup_qt)
endif()
if (("QT_CMAKE_PREFIX_PATH" STREQUAL "") OR (NOT EXISTS "${QT_CMAKE_PREFIX_PATH}"))
calculate_default_qt_dir(${QT_VERSION} QT_DIR)
- set(QT_CMAKE_PREFIX_PATH "${QT_DIR}/lib/cmake")
+ set(QT_CMAKE_PREFIX_PATH "${QT_DIR}/cmake")
else()
# figure out where the qt dir is
get_filename_component(QT_DIR "${QT_CMAKE_PREFIX_PATH}/../../" ABSOLUTE)
Index: hifi-interface-84/interface/CMakeLists.txt
===================================================================
--- hifi-interface-84.orig/interface/CMakeLists.txt
+++ hifi-interface-84/interface/CMakeLists.txt
@@ -35,7 +35,7 @@ else ()
add_custom_command(
OUTPUT ${RESOURCES_RCC}
DEPENDS ${RESOURCES_QRC} ${GENERATE_QRC_DEPENDS}
- COMMAND "${QT_DIR}/bin/rcc"
+ COMMAND "rcc"
ARGS ${RESOURCES_QRC} -binary -o ${RESOURCES_RCC}
)
endif()
@@ -399,6 +399,13 @@ else()
optional_win_executable_signing()
endif()
+
+ install(
+ DIRECTORY "$<TARGET_FILE_DIR:${TARGET_NAME}>/"
+ DESTINATION ${INTERFACE_INSTALL_DIR}
+ COMPONENT ${CLIENT_COMPONENT}
+ )
+
endif()
if (SCRIPTS_INSTALL_DIR)
Index: hifi-interface-84/tools/nitpick/CMakeLists.txt
===================================================================
--- hifi-interface-84.orig/tools/nitpick/CMakeLists.txt
+++ hifi-interface-84/tools/nitpick/CMakeLists.txt
@@ -12,7 +12,7 @@ generate_qrc(OUTPUT ${RESOURCES_QRC} PAT
add_custom_command(
OUTPUT ${RESOURCES_RCC}
DEPENDS ${RESOURCES_QRC} ${GENERATE_QRC_DEPENDS}
- COMMAND "${QT_DIR}/bin/rcc"
+ COMMAND "rcc"
ARGS ${RESOURCES_QRC} -binary -o ${RESOURCES_RCC}
)

1
debian/patches/series vendored Normal file
View file

@ -0,0 +1 @@
hifi_use_system_qt.diff

24
debian/rules vendored Executable file
View file

@ -0,0 +1,24 @@
#!/usr/bin/make -f
%:
dh $@
override_dh_auto_configure:
mkdir obj-$(DEB_TARGET_MULTIARCH)
(cd obj-$(DEB_TARGET_MULTIARCH) && cmake .. -DCMAKE_INSTALL_PREFIX=/opt/hifi -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON "-GUnix Makefiles" -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCLIENT_ONLY=ON -DDOWNLOAD_SERVERLESS_CONTENT=ON -DCMAKE_CXX_COMPILER=/usr/lib/llvm-7/bin/clang\+\+ -DOpenGL_GL_PREFERENCE=GLVND)
override_dh_auto_build:
(cd obj-$(DEB_TARGET_MULTIARCH) && make -j4)
S=obj-$(DEB_TARGET_MULTIARCH)
I=debian/hifi-interface/opt/hifi/interface
override_dh_auto_install:
cp $(S)/interface/interface $(I)
cp $(S)/ext/makefiles/steamworks/project/src/steamworks/redistributable_bin/linux64/libsteam_api.so $(I)
cp $(S)/ext/makefiles/quazip/project/build/libquazip5.so.1 $(I)
cp $(S)/ext/makefiles/polyvox/project/build/library/PolyVoxCore/libPolyVoxCore.so.0 $(I)
cp $(S)/interface/resources.rcc $(I)
cp -r $(S)/interface/scripts $(I)/scripts
cp -r $(S)/interface/plugins $(I)/plugins

1
debian/source/format vendored Normal file
View file

@ -0,0 +1 @@
3.0 (quilt)

6
debian/source/include-binaries vendored Normal file
View file

@ -0,0 +1,6 @@
interface/compiledResources/resources.rcc
tools/nitpick/compiledResources/resources.rcc
__pycache__/hifi_android.cpython-37.pyc
__pycache__/hifi_singleton.cpython-37.pyc
__pycache__/hifi_utils.cpython-37.pyc
__pycache__/hifi_vcpkg.cpython-37.pyc