From ea46b29b4e8a25df3171e959d69aeb52e93f798e Mon Sep 17 00:00:00 2001 From: Zoe Knox Date: Wed, 8 May 2024 21:12:53 +0000 Subject: [PATCH] More build fixups --- CoreServices/WindowServer/libevdev/Makefile | 3 ++- Frameworks/AppKit/Makefile | 1 + Frameworks/AppKit/fontconfig/Makefile | 3 ++- Frameworks/AppKit/gperf/Makefile | 3 ++- Frameworks/AppKit/libxkbcommon/Makefile | 2 +- Frameworks/OpenGL/mesa/Makefile | 1 + Frameworks/OpenGL/wayland/scanner/Makefile | 2 +- Makefile.inc1 | 1 + lib/Makefile | 1 + lib/libc/Makefile | 1 - lib/libsys/Makefile | 1 - lib/libxml2/Makefile | 1 + tools/ravynOS/build.sh | 7 ++++++- 13 files changed, 19 insertions(+), 8 deletions(-) diff --git a/CoreServices/WindowServer/libevdev/Makefile b/CoreServices/WindowServer/libevdev/Makefile index 34626188a44b..3d74f49088c9 100644 --- a/CoreServices/WindowServer/libevdev/Makefile +++ b/CoreServices/WindowServer/libevdev/Makefile @@ -46,7 +46,8 @@ ${INCSDIR}: .PHONY mkdir -vp ${OBJTOP}/tmp/${INCSDIR} event-names.h: .PHONY - ${.CURDIR}/libevdev/make-event-names.py \ + ${OBJTOP}/tmp/usr/bin/python3 \ + ${.CURDIR}/libevdev/make-event-names.py \ ${.CURDIR}/include/linux/linux/input.h \ ${.CURDIR}/include/linux/linux/input-event-codes.h >${.TARGET} diff --git a/Frameworks/AppKit/Makefile b/Frameworks/AppKit/Makefile index c9ec80ce3f26..a0bd2ee0731d 100644 --- a/Frameworks/AppKit/Makefile +++ b/Frameworks/AppKit/Makefile @@ -6,6 +6,7 @@ MK_AUTO_OBJ=yes NO_FMWK_COMMON=yes .include "../framework.common.mk" +SUBDIR+= gperf .WAIT SUBDIR+= fontconfig SUBDIR+= libxkbcommon diff --git a/Frameworks/AppKit/fontconfig/Makefile b/Frameworks/AppKit/fontconfig/Makefile index 220501e1bb62..9c7b9b42bdf8 100644 --- a/Frameworks/AppKit/fontconfig/Makefile +++ b/Frameworks/AppKit/fontconfig/Makefile @@ -31,10 +31,11 @@ all: build ${MAKEOBJDIR}/Makefile: mkdir -p ${MAKEOBJDIR} cd ${MAKEOBJDIR}; LDFLAGS="${LDFLAGS:S/-L /-L/Wg}" \ + PYTHON=${OBJTOP}/tmp/usr/bin/python3 \ ${.CURDIR}/configure ${CONFIGURE_ARGS} build: ${MAKEOBJDIR}/Makefile - ${GMAKE} -C ${MAKEOBJDIR} + PYTHON=${OBJTOP}/tmp/usr/bin/python3 ${GMAKE} -C ${MAKEOBJDIR} clean: rm -rf ${MAKEOBJDIR} diff --git a/Frameworks/AppKit/gperf/Makefile b/Frameworks/AppKit/gperf/Makefile index 54cebeae003e..0ed4b28262ec 100644 --- a/Frameworks/AppKit/gperf/Makefile +++ b/Frameworks/AppKit/gperf/Makefile @@ -10,7 +10,8 @@ CONFIGURE_ARGS+= --prefix=/usr \ --localstatedir=/var all: build configure: .EXEC - ${.CURDIR}/configure ${CONFIGURE_ARGS} + mkdir -p ${MAKEOBJDIR} + cd ${MAKEOBJDIR}; ${.CURDIR}/configure ${CONFIGURE_ARGS} build: configure ${GMAKE} -C ${MAKEOBJDIR} diff --git a/Frameworks/AppKit/libxkbcommon/Makefile b/Frameworks/AppKit/libxkbcommon/Makefile index 53bc61d11026..b8768f2b862f 100644 --- a/Frameworks/AppKit/libxkbcommon/Makefile +++ b/Frameworks/AppKit/libxkbcommon/Makefile @@ -87,4 +87,4 @@ src/xkbcomp/parser.c: src/xkbcomp/parser.y .include -${OBJS}: config.h src/xkbcomp/parser.c +${OBJS}: obj config.h src/xkbcomp/parser.c diff --git a/Frameworks/OpenGL/mesa/Makefile b/Frameworks/OpenGL/mesa/Makefile index 85f2941e3a15..51ea06bdad4f 100644 --- a/Frameworks/OpenGL/mesa/Makefile +++ b/Frameworks/OpenGL/mesa/Makefile @@ -38,6 +38,7 @@ build: -Dgbm=enabled -Dxmlconfig=disabled -Dexpat=disabled \ ${MAKEOBJDIR} ${.CURDIR} sed -i.bak -e 's@-I/usr/include@@g' ${MAKEOBJDIR}/build.ninja + PATH=${OBJTOP}/tmp/usr/bin:${OBJTOP}/tmp/legacy/bin:${OBJTOP}/Frameworks/OpenGL/wayland/scanner:${OBJTOP}/usr.bin/clang/llvm-ar \ ${NINJA} install: diff --git a/Frameworks/OpenGL/wayland/scanner/Makefile b/Frameworks/OpenGL/wayland/scanner/Makefile index 7c6ea535121c..34b96a0f05a1 100644 --- a/Frameworks/OpenGL/wayland/scanner/Makefile +++ b/Frameworks/OpenGL/wayland/scanner/Makefile @@ -20,7 +20,7 @@ LDFLAGS= -lbsdxml WARNS?= 2 wayland.dtd.h:: - python3 ${.CURDIR}/../src/embed.py \ + ${OBJTOP}/tmp/usr/bin/python3 ${.CURDIR}/../src/embed.py \ ${.CURDIR}/../protocol/wayland.dtd wayland_dtd >${.TARGET} wayland-version.h: ../src/wayland-version.h.in diff --git a/Makefile.inc1 b/Makefile.inc1 index 873b1c0a0d0e..6c8a6859a0bd 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -691,6 +691,7 @@ PACKAGE= kernel # This stage installs a previously built world. # +CFLAGS+= -D__RAVYNOS__ -D__MACH__ BOOTSTRAPPING?= 0 # Keep these in sync MINIMUM_SUPPORTED_OSREL?= 1104001 diff --git a/lib/Makefile b/lib/Makefile index 62b5581ce2e8..e033a44423c6 100644 --- a/lib/Makefile +++ b/lib/Makefile @@ -179,6 +179,7 @@ SUBDIR_DEPEND_liblzma= libthr .if ${MK_OFED} != "no" SUBDIR_DEPEND_libpcap= ofed .endif +SUBDIR_DEPEND_libxml2= libdl SUBDIR_DEPEND_libxpc= libdispatch SUBDIR_DEPEND_nss_tacplus= libtacplus diff --git a/lib/libc/Makefile b/lib/libc/Makefile index 03231a1a9f2c..674986a7e065 100644 --- a/lib/libc/Makefile +++ b/lib/libc/Makefile @@ -26,7 +26,6 @@ LIBC_ARCH=${MACHINE_CPUARCH} # To include legacy CSRG SCCS ID strings, remove -DNO__SCCSID from CFLAGS. # To include RCS ID strings from other BSD projects, remove -DNO__RCSID from CFLAGS. CFLAGS+=-DNO__SCCSID -DNO__RCSID -CFLAGS+=-D__MACH__ -D__RAVYNOS__ LIB=c SHLIB_MAJOR= 7 diff --git a/lib/libsys/Makefile b/lib/libsys/Makefile index 73eca78029b3..b4c0e91e860c 100644 --- a/lib/libsys/Makefile +++ b/lib/libsys/Makefile @@ -28,7 +28,6 @@ INCS= libsys.h _libsys.h CFLAGS+=-I${LIBSYS_SRCTOP}/include -I${LIBC_SRCTOP}/include CFLAGS+=-I${LIBSYS_SRCTOP}/${LIBC_ARCH} CFLAGS+=-I${LIBC_SRCTOP}/${LIBC_ARCH} -CFLAGS+=-D__MACH__ -D__RAVYNOS__ .PATH: ${LIBC_SRCTOP}/string SRCS+= memcpy.c memset.c strlcpy.c diff --git a/lib/libxml2/Makefile b/lib/libxml2/Makefile index 0eba88667fd7..2b3aadd90985 100644 --- a/lib/libxml2/Makefile +++ b/lib/libxml2/Makefile @@ -4,6 +4,7 @@ PATH+= ${OBJTOP}/tmp/legacy/bin all: cmake -G "Unix Makefiles" \ + -DCMAKE_SHARED_LINKER_FLAGS="-L${OBJTOP}/lib/libdl" \ -DPKG_CONFIG_EXECUTABLE=/usr/bin/true \ -DCMAKE_INSTALL_PREFIX=${PREFIX} \ -DLIBXML2_WITH_SAX1=ON \ diff --git a/tools/ravynOS/build.sh b/tools/ravynOS/build.sh index d079a1150e59..5eb13dcc6d24 100755 --- a/tools/ravynOS/build.sh +++ b/tools/ravynOS/build.sh @@ -26,7 +26,12 @@ install() { base_build() { cd ${CIRRUS_WORKING_DIR} - make -j${CORES} MALLOC_PRODUCTION=1 WITHOUT_CLEAN=1 MK_LIB32=no COMPILER_TYPE=clang buildworld + make -j${CORES} MALLOC_PRODUCTION=1 WITHOUT_CLEAN=1 \ + MK_LIB32=no MK_LLVM_TARGET_X86=yes \ + MK_LLVM_TARGET_ARM=yes MK_LLVM_TARGET_AARCH64=yes \ + MK_LLVM_TARGET_RISCV=no MK_LLVM_TARGET_POWERPC=no \ + MK_LLVM_TARGET_MIPS=no MK_LLVM_TARGET_BPF=no \ + COMPILER_TYPE=clang buildworld if [ $? -ne 0 ]; then exit $?; fi }