Skip to content

Commit 81808d4

Browse files
committed
Set cmake defaults and qmakespec
1 parent 73e85e0 commit 81808d4

3 files changed

Lines changed: 8 additions & 4 deletions

File tree

qt/Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,4 +106,6 @@ RUN --mount=target=/root/qt6,from=qt6base,src=/root/qt6 \
106106
&& rm -r qt6-build \
107107
&& apt-get autoremove -y \
108108
&& apt-get clean \
109-
&& rm -rf /var/lib/apt/lists/* /var/log/dpkg.log /var/log/apt
109+
&& rm -rf /var/lib/apt/lists/* /var/log/dpkg.log /var/log/apt \
110+
&& echo 'export QMAKESPEC=/usr/mkspecs/devices/linux-aarch64-remarkable-g++' >> /opt/x-tools/switch-aarch64.sh \
111+
&& echo 'export QMAKESPEC=/usr/mkspecs/devices/linux-arm-remarkable-g++' >> /opt/x-tools/switch-arm.sh

qt/linux-arm-remarkable-g++/qmake.conf

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,6 @@ QMAKE_AR="arm-linux-gnueabihf-ar"
1515
QMAKE_OBJCOPY="arm-linux-gnueabihf-objcopy"
1616
QMAKE_NM="arm-linux-gnueabihf-nm -P"
1717
QMAKE_STRIP="arm-linux-gnueabihf-strip"
18-
QMAKE_CFLAGS="-mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64"
19-
QMAKE_CXXFLAGS="-mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64"
20-
QMAKE_LFLAGS="-mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64 -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed"
18+
QMAKE_CFLAGS="-mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64 --sysroot=$$(SYSROOT)"
19+
QMAKE_CXXFLAGS="-mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64 --sysroot=$$(SYSROOT)"
20+
QMAKE_LFLAGS="-mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64 -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed --sysroot=$$(SYSROOT)"

toolchain/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,7 @@ export PKG_CONFIG_SYSROOT_DIR="/opt/x-tools/$NGCONFIG/$NGCONFIG/sysroot"
149149
export SYSROOT="/opt/x-tools/$NGCONFIG/$NGCONFIG/sysroot"
150150
export NGCONFIG="$NGCONFIG"
151151
export TARGET_PREFIX="$CHOST"
152+
export CMAKE_TOOLCHAIN_FILE="/usr/share/cmake/$CHOST.cmake"
152153
EOF
153154

154155
RUN touch /opt/x-tools/switch-aarch64.sh && chmod +x /opt/x-tools/switch-aarch64.sh && cat <<EOF > /opt/x-tools/switch-aarch64.sh
@@ -161,6 +162,7 @@ export PKG_CONFIG_SYSROOT_DIR="/opt/x-tools/$NGCONFIG_AARCH64/$NGCONFIG_AARCH64/
161162
export SYSROOT="/opt/x-tools/$NGCONFIG_AARCH64/$NGCONFIG_AARCH64/sysroot"
162163
export NGCONFIG="$NGCONFIG_AARCH64"
163164
export TARGET_PREFIX="$CHOST_AARCH64"
165+
export CMAKE_TOOLCHAIN_FILE="/usr/share/cmake/$CHOST_AARCH64.cmake"
164166
EOF
165167

166168
# Configure Opkg

0 commit comments

Comments
 (0)