- Improve gendib build.
- Add gendib generated source files.
- Add win32k to build. Dedicated to Timo ;)

svn path=/branches/cmake-bringup/; revision=48690
This commit is contained in:
Amine Khaldi 2010-09-03 00:03:00 +00:00
parent 50bf553ad0
commit f61be19dd9
6 changed files with 470 additions and 32 deletions

View file

@ -26,7 +26,7 @@ include_directories(${REACTOS_BINARY_DIR}/include)
add_subdirectory(tools)
add_subdirectory(lib)
export(TARGETS widl winebuild nci buildno FILE ${CMAKE_BINARY_DIR}/ImportExecutables.cmake NAMESPACE native- )
export(TARGETS widl winebuild nci buildno gendib FILE ${CMAKE_BINARY_DIR}/ImportExecutables.cmake NAMESPACE native- )
else()
@ -108,48 +108,61 @@ add_subdirectory(drivers)
add_subdirectory(hal)
add_subdirectory(lib)
add_subdirectory(ntoskrnl)
add_subdirectory(subsystems)
# nci generated intermediate files
set(nci_output
${REACTOS_BINARY_DIR}/ntoskrnl/include/internal/napi.h
${REACTOS_BINARY_DIR}/subsystems/win32/win32k/include/napi.h
${REACTOS_BINARY_DIR}/lib/ntdllsys/ntdll.S
${REACTOS_BINARY_DIR}/ntoskrnl/ex/zw.S
${REACTOS_BINARY_DIR}/lib/win32ksys/win32k.S
${REACTOS_BINARY_DIR}/dll/ntdll/def/ntsys.pspec
)
${REACTOS_BINARY_DIR}/ntoskrnl/include/internal/napi.h
${REACTOS_BINARY_DIR}/subsystems/win32/win32k/include/napi.h
${REACTOS_BINARY_DIR}/lib/ntdllsys/ntdll.S
${REACTOS_BINARY_DIR}/ntoskrnl/ex/zw.S
${REACTOS_BINARY_DIR}/lib/win32ksys/win32k.S
${REACTOS_BINARY_DIR}/dll/ntdll/def/ntsys.pspec)
# stupid nci tool can't create folders itself, se we're gonna create them for it
set(nci_folders
${CMAKE_CURRENT_BINARY_DIR}/dll/ntdll/def
${CMAKE_CURRENT_BINARY_DIR}/lib/ntdllsys/ntdll
${CMAKE_CURRENT_BINARY_DIR}/lib/win32ksys
${CMAKE_CURRENT_BINARY_DIR}/ntoskrnl/include/internal
${CMAKE_CURRENT_BINARY_DIR}/ntoskrnl/ex
${CMAKE_CURRENT_BINARY_DIR}/subsystems/win32/win32k/include
)
${CMAKE_CURRENT_BINARY_DIR}/dll/ntdll/def
${CMAKE_CURRENT_BINARY_DIR}/lib/ntdllsys/ntdll
${CMAKE_CURRENT_BINARY_DIR}/lib/win32ksys
${CMAKE_CURRENT_BINARY_DIR}/ntoskrnl/include/internal
${CMAKE_CURRENT_BINARY_DIR}/ntoskrnl/ex
${CMAKE_CURRENT_BINARY_DIR}/subsystems/win32/win32k/include)
file(MAKE_DIRECTORY ${nci_folders})
ADD_CUSTOM_COMMAND(
OUTPUT ${nci_output}
COMMAND native-nci -arch ${ARCH} ${REACTOS_SOURCE_DIR}/ntoskrnl/sysfuncs.lst ${REACTOS_SOURCE_DIR}/subsystems/win32/win32k/w32ksvc.db ${nci_output}
DEPENDS native-nci ${nci_folders}
)
add_custom_command(
OUTPUT ${nci_output}
COMMAND native-nci -arch ${ARCH} ${REACTOS_SOURCE_DIR}/ntoskrnl/sysfuncs.lst ${REACTOS_SOURCE_DIR}/subsystems/win32/win32k/w32ksvc.db ${nci_output}
DEPENDS native-nci ${nci_folders})
ADD_CUSTOM_TARGET(ntdll_S ALL DEPENDS ${REACTOS_BINARY_DIR}/lib/ntdllsys/ntdll.S)
ADD_CUSTOM_TARGET(win32k_S ALL DEPENDS ${REACTOS_BINARY_DIR}/lib/win32ksys/win32k.S)
ADD_CUSTOM_TARGET(ntsys_pspec ALL DEPENDS ${REACTOS_BINARY_DIR}/dll/ntdll/def/ntsys.pspec)
ADD_CUSTOM_TARGET(kernel_napi ALL DEPENDS ${REACTOS_BINARY_DIR}/ntoskrnl/include/internal/napi.h)
ADD_CUSTOM_TARGET(subsystem_napi ALL DEPENDS ${REACTOS_BINARY_DIR}/subsystems/win32/win32k/include/napi.h)
ADD_CUSTOM_TARGET(kernel_zw ALL DEPENDS ${REACTOS_BINARY_DIR}/ntoskrnl/ex/zw.S)
add_custom_target(ntdll_S ALL DEPENDS ${REACTOS_BINARY_DIR}/lib/ntdllsys/ntdll.S)
add_custom_target(win32k_S ALL DEPENDS ${REACTOS_BINARY_DIR}/lib/win32ksys/win32k.S)
add_custom_target(ntsys_pspec ALL DEPENDS ${REACTOS_BINARY_DIR}/dll/ntdll/def/ntsys.pspec)
add_custom_target(kernel_napi ALL DEPENDS ${REACTOS_BINARY_DIR}/ntoskrnl/include/internal/napi.h)
add_custom_target(subsystem_napi ALL DEPENDS ${REACTOS_BINARY_DIR}/subsystems/win32/win32k/include/napi.h)
add_custom_target(kernel_zw ALL DEPENDS ${REACTOS_BINARY_DIR}/ntoskrnl/ex/zw.S)
file(MAKE_DIRECTORY ${REACTOS_BINARY_DIR}/include/reactos)
ADD_CUSTOM_COMMAND(OUTPUT ${REACTOS_BINARY_DIR}/include/reactos/buildno.h
COMMAND native-buildno ${REACTOS_BINARY_DIR}/include/reactos/buildno.h
DEPENDS ${REACTOS_SOURCE_DIR}/include/reactos/version.h)
ADD_CUSTOM_TARGET(buildno_header ALL DEPENDS ${REACTOS_BINARY_DIR}/include/reactos/buildno.h)
add_custom_command(
OUTPUT ${REACTOS_BINARY_DIR}/include/reactos/buildno.h
COMMAND native-buildno ${REACTOS_BINARY_DIR}/include/reactos/buildno.h
DEPENDS ${REACTOS_SOURCE_DIR}/include/reactos/version.h)
add_custom_target(buildno_header ALL DEPENDS ${REACTOS_BINARY_DIR}/include/reactos/buildno.h)
file(MAKE_DIRECTORY ${REACTOS_BINARY_DIR}/subsystems/win32/win32k/dib)
list(APPEND OUTPUT_FILES
${REACTOS_BINARY_DIR}/subsystems/win32/win32k/dib/dib8gen.c
${REACTOS_BINARY_DIR}/subsystems/win32/win32k/dib/dib16gen.c
${REACTOS_BINARY_DIR}/subsystems/win32/win32k/dib/dib32gen.c)
add_custom_command(
OUTPUT ${OUTPUT_FILES}
COMMAND native-gendib ${REACTOS_BINARY_DIR}/subsystems/win32/win32k/dib
DEPENDS native-gendib)
add_custom_target(gendib_generated ALL DEPENDS ${OUTPUT_FILES})
endif()

Binary file not shown.

View file

@ -0,0 +1,2 @@
add_subdirectory(win32)

View file

@ -0,0 +1,2 @@
add_subdirectory(win32k)

View file

@ -0,0 +1,190 @@
set(CMAKE_C_CREATE_SHARED_LIBRARY "<CMAKE_C_COMPILER> <CMAKE_SHARED_LIBRARY_C_FLAGS> <LINK_FLAGS> <CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS> -o <TARGET> <OBJECTS> <LINK_LIBRARIES>")
include_directories(.)
include_directories(include)
include_directories(${REACTOS_SOURCE_DIR}/ntoskrnl/include)
include_directories(${REACTOS_SOURCE_DIR}/lib/3rdparty/freetype/include)
include_directories(${REACTOS_SOURCE_DIR}/include/reactos/subsys)
include_directories(${REACTOS_SOURCE_DIR}/include/reactos/drivers)
add_definitions(-DLANGPACK)
add_definitions(-D_WIN32K_)
list(APPEND SOURCE
dib/dib1bpp.c
dib/dib4bpp.c
dib/dib8bpp.c
dib/dib16bpp.c
dib/dib24bpp.c
dib/dib32bpp.c
dib/dib.c
dib/floodfill.c
dib/stretchblt.c
eng/alphablend.c
eng/bitblt.c
eng/engbrush.c
eng/engevent.c
eng/clip.c
eng/copybits.c
eng/debug.c
eng/device.c
eng/driverobj.c
eng/error.c
eng/float.c
eng/gradient.c
eng/lineto.c
eng/mapping.c
eng/mem.c
eng/engmisc.c
eng/mouse.c
eng/paint.c
eng/perfcnt.c
eng/semaphor.c
eng/sort.c
eng/string.c
eng/stretchblt.c
eng/surface.c
eng/transblt.c
eng/engwindow.c
eng/xlate.c
ldr/loader.c
main/dllmain.c
misc/driver.c
misc/err.c
misc/file.c
misc/math.c
misc/rtlstr.c
misc/copy.c
misc/registry.c
misc/usrheap.c
ntddraw/ddraw.c
ntddraw/dd.c
ntddraw/ddsurf.c
ntddraw/d3d.c
ntddraw/dvp.c
ntddraw/mocomp.c
ntddraw/eng.c
ntddraw/dxeng.c
ntuser/accelerator.c
ntuser/callback.c
ntuser/callproc.c
ntuser/caret.c
ntuser/class.c
ntuser/clipboard.c
ntuser/csr.c
ntuser/cursoricon.c
ntuser/defwnd.c
ntuser/desktop.c
ntuser/display.c
ntuser/event.c
ntuser/focus.c
ntuser/guicheck.c
ntuser/hook.c
ntuser/hotkey.c
ntuser/input.c
ntuser/keyboard.c
ntuser/kbdlayout.c
ntuser/menu.c
ntuser/message.c
ntuser/metric.c
ntuser/misc.c
ntuser/monitor.c
ntuser/msgqueue.c
ntuser/ntstubs.c
ntuser/ntuser.c
ntuser/painting.c
ntuser/prop.c
ntuser/scrollbar.c
ntuser/session.c
ntuser/simplecall.c
ntuser/sysparams.c
ntuser/timer.c
ntuser/useratom.c
ntuser/vis.c
ntuser/windc.c
ntuser/window.c
ntuser/winpos.c
ntuser/winsta.c
ntuser/object.c
objects/arc.c
objects/bezier.c
objects/bitblt.c
objects/bitmaps.c
objects/brush.c
objects/cliprgn.c
objects/coord.c
objects/dcattr.c
objects/dclife.c
objects/dcobjs.c
objects/dcstate.c
objects/dcutil.c
objects/device.c
objects/dibobj.c
objects/drawing.c
objects/fillshap.c
objects/font.c
objects/freetype.c
objects/gdibatch.c
objects/gdiobj.c
objects/icm.c
objects/line.c
objects/metafile.c
objects/palette.c
objects/path.c
objects/pen.c
objects/polyfill.c
objects/print.c
objects/rect.c
objects/region.c
objects/stockobj.c
objects/text.c
objects/wingl.c
objects/xformobj.c
stubs/stubs.c
stubs/umpdstubs.c
win32k.rc)
list(APPEND GENDIB_GENERATED
${CMAKE_CURRENT_BINARY_DIR}/dib/dib8gen.c
${CMAKE_CURRENT_BINARY_DIR}/dib/dib16gen.c
${CMAKE_CURRENT_BINARY_DIR}/dib/dib32gen.c)
set_source_files_properties(${GENDIB_GENERATED} PROPERTIES GENERATED TRUE)
list(APPEND SOURCE ${GENDIB_GENERATED})
if(ARCH MATCHES i386)
list(APPEND SOURCE
dib/i386/dib24bpp_hline.s
dib/i386/dib32bpp_hline.s
dib/i386/dib32bpp_colorfill.s
eng/i386/floatobj.S
misc/i386/cos_asm.s
misc/i386/sin_asm.s
misc/i386/atan2_asm.s
misc/i386/floor_asm.s
misc/i386/ceil_asm.s)
else()
list(APPEND SOURCE
dib/dib24bppc.c
dib/dib32bppc.c)
endif(ARCH MATCHES i386)
add_library(win32k SHARED
${CMAKE_CURRENT_BINARY_DIR}/win32k_pch.h.gch
${SOURCE})
set_target_properties(win32k PROPERTIES LINK_FLAGS "-Wl,-entry,_DriverEntry@8 -Wl,--image-base,0x00010000 -Wl,--subsystem,native" SUFFIX ".sys")
target_link_libraries(win32k
${CMAKE_CURRENT_SOURCE_DIR}/win32k_i386.def
pseh
${REACTOS_SOURCE_DIR}/ntoskrnl/libntoskrnl.a
${REACTOS_SOURCE_DIR}/hal/halx86/libhal.a
${REACTOS_SOURCE_DIR}/drivers/video/font/ftfd/libftfd.a
dxguid
libcntpr)
add_pch(win32k ${CMAKE_CURRENT_SOURCE_DIR}/pch.h ${SOURCE})
add_dependencies(win32k psdk gendib_generated bugcodes subsystem_napi buildno_header)

View file

@ -0,0 +1,231 @@
; File generated automatically from obj-i386\subsystems\win32\win32k\win32k_win32k.spec; do not edit!
LIBRARY win32k.sys
EXPORTS
FLOATOBJ_AddFloatObj@8=FLOATOBJ_Add@8 @1
FLOATOBJ_DivFloatObj@8=FLOATOBJ_Div@8 @2
FLOATOBJ_MulFloatObj@8=FLOATOBJ_Mul@8 @3
FLOATOBJ_SubFloatObj@8=FLOATOBJ_Sub@8 @4
BRUSHOBJ_hGetColorTransform@4 @5
BRUSHOBJ_pvAllocRbrush@8 @6
BRUSHOBJ_pvGetRbrush@4 @7
BRUSHOBJ_ulGetBrushColor@4 @8
CLIPOBJ_bEnum@12 @9
CLIPOBJ_cEnumStart@20 @10
CLIPOBJ_ppoGetPath@4 @11
EngAcquireSemaphore@4 @12
EngAllocMem@12 @13
EngAllocPrivateUserMem@12 @14
EngAllocSectionMem@16 @15
EngAllocUserMem@8 @16
EngAlphaBlend@28 @17
EngAssociateSurface@12 @18
EngBitBlt@44 @19
EngBugCheckEx@20=NTOSKRNL.KeBugCheckEx @20
EngCheckAbort@4 @21
EngClearEvent@4 @22
EngComputeGlyphSet@12 @23
EngControlSprites@8 @24
EngCopyBits@24 @25
EngCreateBitmap@24 @26
EngCreateClip@0 @27
EngCreateDeviceBitmap@16 @28
EngCreateDeviceSurface@16 @29
EngCreateDriverObj@12 @30
EngCreateEvent@4 @31
EngCreatePalette@24 @32
EngCreatePath@0 @33
EngCreateSemaphore@0 @34
EngCreateWnd@20 @35
EngDebugBreak@0=NTOSKRNL.DbgBreakPoint @36
EngDebugPrint@12 @37
EngDeleteClip@4 @38
EngDeleteDriverObj@12 @39
EngDeleteEvent@4 @40
EngDeleteFile@4 @41
EngDeletePalette@4 @42
EngDeletePath@4 @43
EngDeleteSafeSemaphore@4 @44
EngDeleteSemaphore@4 @45
EngDeleteSurface@4 @46
EngDeleteWnd@4 @47
EngDeviceIoControl@28 @48
EngDitherColor@16 @49
EngDxIoctl@12 @50
EngEnumForms@24 @51
EngEraseSurface@12 @52
EngFileIoControl@28 @53
EngFileWrite@16 @54
EngFillPath@28 @55
EngFindImageProcAddress@8 @56
EngFindResource@16 @57
EngFntCacheAlloc@8 @58
EngFntCacheFault@8 @59
EngFntCacheLookUp@8 @60
EngFreeMem@4 @61
EngFreeModule@4 @62
EngFreePrivateUserMem@8 @63
EngFreeSectionMem@8 @64
EngFreeUserMem@4 @65
EngGetCurrentCodePage@8 @66
EngGetCurrentProcessId@0=NTOSKRNL.PsGetCurrentProcessId @67
EngGetCurrentThreadId@0=NTOSKRNL.PsGetCurrentThreadId @68
EngGetDriverName@4 @69
EngGetFileChangeTime@8 @70
EngGetFilePath@8 @71
EngGetForm@24 @72
EngGetLastError@0 @73
EngGetPrinter@20 @74
EngGetPrinterData@24 @75
EngGetPrinterDataFileName@4 @76
EngGetPrinterDriver@24 @77
EngGetProcessHandle@0 @78
EngGetTickCount@0 @79
EngGetType1FontList@24 @80
EngGradientFill@40 @81
EngHangNotification@8 @82
EngInitializeSafeSemaphore@4 @83
EngIsSemaphoreOwned@4 @84
EngIsSemaphoreOwnedByCurrentThread@4 @85
EngLineTo@36 @86
EngLoadImage@4 @87
EngLoadModule@4 @88
EngLoadModuleForWrite@8 @89
EngLockDirectDrawSurface@4 @90
EngLockDriverObj@4 @91
EngLockSurface@4 @92
EngLpkInstalled@0 @93
EngMapEvent@20 @94
EngMapFile@12 @95
EngMapFontFile@12 @96
EngMapFontFileFD@12 @97
EngMapModule@8 @98
EngMapSection@16 @99
EngMarkBandingSurface@4 @100
EngModifySurface@32 @101
EngMovePointer@16 @102
EngMulDiv@12 @103
EngMultiByteToUnicodeN@20=NTOSKRNL.RtlMultiByteToUnicodeN @104
EngMultiByteToWideChar@20 @105
EngNineGrid@36 @106
EngPaint@20 @107
EngPlgBlt@44 @108
EngProbeForRead@12=NTOSKRNL.ProbeForRead @109
EngProbeForReadAndWrite@12=NTOSKRNL.ProbeForWrite @110
EngQueryDeviceAttribute@24 @111
EngQueryFileTimeStamp@4 @112
EngQueryLocalTime@4 @113
EngQueryPalette@16 @114
EngQueryPerformanceCounter@4 @115
EngQueryPerformanceFrequency@4 @116
EngQuerySystemAttribute@8 @117
EngReadStateEvent@4 @118
EngReleaseSemaphore@4 @119
EngRestoreFloatingPointState@4 @120
EngSaveFloatingPointState@8 @121
EngSecureMem@8 @122
EngSetEvent@4 @123
EngSetLastError@4 @124
EngSetPointerShape@40 @125
EngSetPointerTag@20 @126
EngSetPrinterData@20 @127
EngSort@16 @128
EngStretchBlt@44 @129
EngStretchBltROP@52 @130
EngStrokeAndFillPath@40 @131
EngStrokePath@32 @132
EngTextOut@40 @133
EngTransparentBlt@32 @134
EngUnicodeToMultiByteN@20=NTOSKRNL.RtlUnicodeToMultiByteN @135
EngUnloadImage@4 @136
EngUnlockDirectDrawSurface@4 @137
EngUnlockDriverObj@4 @138
EngUnlockSurface@4 @139
EngUnmapEvent@4 @140
EngUnmapFile@4 @141
EngUnmapFontFile@4 @142
EngUnmapFontFileFD@4 @143
EngUnsecureMem@4 @144
EngWaitForSingleObject@8 @145
EngWideCharToMultiByte@20 @146
EngWritePrinter@16 @147
FLOATOBJ_Add@8 @148
FLOATOBJ_AddFloat@8 @149
FLOATOBJ_AddLong@8 @150
FLOATOBJ_Div@8 @151
FLOATOBJ_DivFloat@8 @152
FLOATOBJ_DivLong@8 @153
FLOATOBJ_Equal@8 @154
FLOATOBJ_EqualLong@8 @155
FLOATOBJ_GetFloat@4 @156
FLOATOBJ_GetLong@4 @157
FLOATOBJ_GreaterThan@8 @158
FLOATOBJ_GreaterThanLong@8 @159
FLOATOBJ_LessThan@8 @160
FLOATOBJ_LessThanLong@8 @161
FLOATOBJ_Mul@8 @162
FLOATOBJ_MulFloat@8 @163
FLOATOBJ_MulLong@8 @164
FLOATOBJ_Neg@4 @165
FLOATOBJ_SetFloat@8 @166
FLOATOBJ_SetLong@8 @167
FLOATOBJ_Sub@8 @168
FLOATOBJ_SubFloat@8 @169
FLOATOBJ_SubLong@8 @170
FONTOBJ_cGetAllGlyphHandles@8 @171
FONTOBJ_cGetGlyphs@20 @172
FONTOBJ_pQueryGlyphAttrs@8 @173
FONTOBJ_pfdg@4 @174
FONTOBJ_pifi@4 @175
FONTOBJ_pjOpenTypeTablePointer@12 @176
FONTOBJ_pvTrueTypeFontFile@8 @177
FONTOBJ_pwszFontFilePaths@8 @178
FONTOBJ_pxoGetXform@4 @179
FONTOBJ_vGetInfo@12 @180
HT_ComputeRGBGammaTable@24 @181
HT_Get8BPPFormatPalette@16 @182
HT_Get8BPPMaskPalette@24 @183
HeapVidMemAllocAligned@20 @184
PALOBJ_cGetColors@16 @185
PATHOBJ_bCloseFigure@4 @186
PATHOBJ_bEnum@8 @187
PATHOBJ_bEnumClipLines@12 @188
PATHOBJ_bMoveTo@12 @189
PATHOBJ_bPolyBezierTo@12 @190
PATHOBJ_bPolyLineTo@12 @191
PATHOBJ_vEnumStart@4 @192
PATHOBJ_vEnumStartClipLines@16 @193
PATHOBJ_vGetBounds@8 @194
RtlAnsiCharToUnicodeChar@4=NTOSKRNL.RtlAnsiCharToUnicodeChar @195
RtlMultiByteToUnicodeN@20=NTOSKRNL.RtlMultiByteToUnicodeN @196
RtlRaiseException@4=NTOSKRNL.RtlRaiseException @197
RtlUnicodeToMultiByteN@20=NTOSKRNL.RtlUnicodeToMultiByteN @198
RtlUnicodeToMultiByteSize@12=NTOSKRNL.RtlUnicodeToMultiByteSize @199
RtlUnwind@16=NTOSKRNL.RtlUnwind @200
RtlUpcaseUnicodeChar@4=NTOSKRNL.RtlUpcaseUnicodeChar @201
RtlUpcaseUnicodeToMultiByteN@20=NTOSKRNL.RtlUpcaseUnicodeToMultiByteN @202
STROBJ_bEnum@12 @203
STROBJ_bEnumPositionsOnly@12 @204
STROBJ_bGetAdvanceWidths@16 @205
STROBJ_dwGetCodePage@4 @206
STROBJ_fxBreakExtra@4 @207
STROBJ_fxCharacterExtra@4 @208
STROBJ_vEnumStart@4 @209
VidMemFree@8 @210
WNDOBJ_bEnum@12 @211
WNDOBJ_cEnumStart@16 @212
WNDOBJ_vSetConsumer@8 @213
XFORMOBJ_bApplyXform@20 @214
XFORMOBJ_iGetFloatObjXform@8 @215
XFORMOBJ_iGetXform@8 @216
XLATEOBJ_cGetPalette@16 @217
XLATEOBJ_hGetColorTransform@4 @218
XLATEOBJ_iXlate@8 @219
XLATEOBJ_piVector@4 @220
_abnormal_termination=NTOSKRNL._abnormal_termination @221
_except_handler2=NTOSKRNL._except_handler2 @222
_global_unwind2=NTOSKRNL._global_unwind2 @223
_itoa=NTOSKRNL._itoa @224
_itow=NTOSKRNL._itow @225
_local_unwind2=NTOSKRNL._local_unwind2 @226