Ticket #7964: HaikuImage_add_Apple_Aluminum_keyboard_layout_files_to_subdir_1.diff

File HaikuImage_add_Apple_Aluminum_keyboard_layout_files_to_subdir_1.diff, 1.7 KB (added by jscipione, 13 years ago)

This patch modifies HaikuImage to add each of the keyboard layout files in the data/system/data/KeyboardLayouts/ dir one-by-one. The Apple Aluminum Keyboard Layout files in this dir are added to an "Apple Aluminum" subdir in the image. The subdirectory is turned into a submenu in the Keymap preference app.

  • build/jam/HaikuImage

    diff --git build/jam/HaikuImage build/jam/HaikuImage
    index 90b9eee..27a3d72 100644
    AddSymlinkToHaikuImage system data Keymaps : Swedish : Finnish ;  
    499499AddSymlinkToHaikuImage system data Keymaps : Slovene : Croatian ;
    500500AddSymlinkToHaikuImage system data Keymaps : US-International : Brazilian ;
    501501
     502# Copy keyboard layout files to the image one-by-one.
    502503local keyboardLayoutsDir
    503504    = [ FDirName $(HAIKU_TOP) data system data KeyboardLayouts ] ;
    504 local keyboardLayouts = [ Glob $(keyboardLayoutsDir) : [^.]* ] ;
    505 AddFilesToHaikuImage system data KeyboardLayouts : $(keyboardLayouts) ;
     505local keyboardLayoutFiles =
     506    "Generic 104-key"
     507    "Generic 105-key International"
     508    "IBM Laptop International"
     509    "Kinesis Advantage"
     510    "Kinesis Ergo Elan International"
     511    "TypeMatrix 2030" ;
     512keyboardLayoutFiles = $(keyboardLayoutFiles:G=keyboard-layout) ;
     513SEARCH on $(keyboardLayoutFiles) = $(keyboardLayoutsDir) ;
     514AddFilesToHaikuImage system data KeyboardLayouts
     515    : $(keyboardLayoutFiles) ;
     516
     517# Add Apple Aluminum keyboard layout files to the image in an Apple Aluminum
     518# subdirectory. The subdirectory is turned into a submenu in the Layout menu
     519# of the Keymap preference app.
     520local appleAluminumFiles =
     521    "Apple Aluminium Extended International"
     522    "Apple Aluminium International"
     523    "Apple Aluminum (US)"
     524    "Apple Aluminum Extended (US)" ;
     525appleAluminumFiles = $(appleAluminumFiles:G=keyboard-layout) ;
     526SEARCH on $(appleAluminumFiles) = $(keyboardLayoutsDir) ;
     527AddFilesToHaikuImage system data KeyboardLayouts Apple\ Aluminum
     528    : $(appleAluminumFiles) ;
    506529
    507530local driverSettingsFiles = <driver-settings>kernel ;
    508531SEARCH on $(driverSettingsFiles)